@deveco/deveco-code 0.0.0-daily-20260921 → 0.0.0-daily-20260924
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +17 -6
- package/postinstall.mjs +10 -3
package/package.json
CHANGED
|
@@ -6,8 +6,18 @@
|
|
|
6
6
|
"scripts": {
|
|
7
7
|
"postinstall": "bun ./postinstall.mjs || node ./postinstall.mjs"
|
|
8
8
|
},
|
|
9
|
-
"version": "0.0.0-daily-
|
|
9
|
+
"version": "0.0.0-daily-20260924",
|
|
10
10
|
"license": "MIT",
|
|
11
|
+
"os": [
|
|
12
|
+
"darwin",
|
|
13
|
+
"linux",
|
|
14
|
+
"win32",
|
|
15
|
+
"openharmony"
|
|
16
|
+
],
|
|
17
|
+
"cpu": [
|
|
18
|
+
"arm64",
|
|
19
|
+
"x64"
|
|
20
|
+
],
|
|
11
21
|
"files": [
|
|
12
22
|
"bin/**/*",
|
|
13
23
|
"postinstall.mjs",
|
|
@@ -16,12 +26,13 @@
|
|
|
16
26
|
"CHANGELOG.md"
|
|
17
27
|
],
|
|
18
28
|
"optionalDependencies": {
|
|
19
|
-
"@deveco/deveco-code-darwin-
|
|
20
|
-
"@deveco/deveco-code-darwin-
|
|
21
|
-
"@deveco/deveco-code-windows-x64-baseline": "0.0.0-daily-
|
|
22
|
-
"@deveco/deveco-code-windows-x64": "0.0.0-daily-
|
|
29
|
+
"@deveco/deveco-code-darwin-x64": "0.0.0-daily-20260924",
|
|
30
|
+
"@deveco/deveco-code-darwin-arm64": "0.0.0-daily-20260924",
|
|
31
|
+
"@deveco/deveco-code-windows-x64-baseline": "0.0.0-daily-20260924",
|
|
32
|
+
"@deveco/deveco-code-windows-x64": "0.0.0-daily-20260924",
|
|
33
|
+
"@deveco/deveco-code-openharmony-arm64": "0.0.0-daily-20260924"
|
|
23
34
|
},
|
|
24
35
|
"dependencies": {
|
|
25
|
-
"@deveco/deveco-cli": "1.3.
|
|
36
|
+
"@deveco/deveco-cli": "1.3.4"
|
|
26
37
|
}
|
|
27
38
|
}
|
package/postinstall.mjs
CHANGED
|
@@ -29,12 +29,19 @@ const base = `${scope}/deveco-code-${platform}-${arch}`
|
|
|
29
29
|
const sourceBinary = platform === "windows" ? "deveco.exe" : "deveco"
|
|
30
30
|
const targetBinary = path.join(__dirname, "bin", "deveco.exe")
|
|
31
31
|
const devecoCliPackageName = "@deveco/deveco-cli"
|
|
32
|
+
const devecoCliBinName = "devecocli"
|
|
32
33
|
|
|
33
34
|
function resolveLocalDevecoCliEntry() {
|
|
34
35
|
const packageJsonPath = require.resolve(`${devecoCliPackageName}/package.json`)
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
const packageRoot = path.dirname(packageJsonPath)
|
|
37
|
+
const bin = JSON.parse(fs.readFileSync(packageJsonPath, "utf8")).bin
|
|
38
|
+
// The platform-split shell package declares `bin.devecocli` at its root; bundled builds ship `dist/cli.js`.
|
|
39
|
+
const declared = typeof bin === "string" ? bin : bin?.[devecoCliBinName]
|
|
40
|
+
const entry = [declared && path.join(packageRoot, declared), path.join(packageRoot, "dist", "cli.js")]
|
|
41
|
+
.filter(Boolean)
|
|
42
|
+
.find((candidate) => fs.existsSync(candidate))
|
|
43
|
+
if (entry) return entry
|
|
44
|
+
throw new Error(`Local dependency "${devecoCliPackageName}" has no CLI entry under ${packageRoot}.`)
|
|
38
45
|
}
|
|
39
46
|
|
|
40
47
|
function writeDevecoCliEntryMarker(installRoot) {
|