@hippox/codegenie 3.33.2026 → 3.35.2026

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.
@@ -1,3 +1,4 @@
1
+
1
2
  const fs = require("fs")
2
3
  const path = require("path")
3
4
 
@@ -43,6 +44,21 @@ function resolvePlatformPackageDir(packageName) {
43
44
  return path.dirname(packageJsonPath)
44
45
  }
45
46
 
47
+ function ensureExecutable(binaryPath) {
48
+ if (process.platform === "win32") {
49
+ return
50
+ }
51
+ try {
52
+ const stats = fs.statSync(binaryPath)
53
+ const mode = stats.mode & 0o777
54
+ if (mode !== 0o755 && mode !== 0o775 && mode !== 0o777) {
55
+ fs.chmodSync(binaryPath, 0o755)
56
+ }
57
+ } catch {
58
+ // ignore permission check failure
59
+ }
60
+ }
61
+
46
62
  function resolveBinary() {
47
63
  const packageName = resolvePackageName()
48
64
  let platformDir = ""
@@ -72,6 +88,8 @@ function resolveBinary() {
72
88
  throw new Error(`[codegenie] Binary file missing from ${packageName}: ${binaryPath}`)
73
89
  }
74
90
 
91
+ ensureExecutable(binaryPath)
92
+
75
93
  return {
76
94
  packageName,
77
95
  binaryPath,
@@ -85,3 +103,5 @@ module.exports = {
85
103
  resolvePlatformPackageDir,
86
104
  resolvePackageName,
87
105
  }
106
+
107
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hippox/codegenie",
3
- "version": "3.33.2026",
3
+ "version": "3.35.2026",
4
4
  "private": false,
5
5
  "description": "HarmonyOS AI 开发 CLI,通过 npm 分发平台二进制",
6
6
  "license": "MIT",
@@ -26,9 +26,9 @@
26
26
  "ai"
27
27
  ],
28
28
  "optionalDependencies": {
29
- "@hippox/codegenie-darwin-arm64": "3.33.2026",
30
- "@hippox/codegenie-darwin-x64": "3.33.2026",
31
- "@hippox/codegenie-win32-x64": "3.33.2026"
29
+ "@hippox/codegenie-darwin-arm64": "3.35.2026",
30
+ "@hippox/codegenie-darwin-x64": "3.35.2026",
31
+ "@hippox/codegenie-win32-x64": "3.35.2026"
32
32
  },
33
33
  "publishConfig": {
34
34
  "access": "public"