@nubjs/nub 0.0.19 → 0.0.20
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/bin/launch.js +8 -0
- package/package.json +9 -9
package/bin/launch.js
CHANGED
|
@@ -115,6 +115,14 @@ function healPathEntry(verb, nativePath) {
|
|
|
115
115
|
module.exports = function launch(argv0Name) {
|
|
116
116
|
const verb = argv0Name || "nub";
|
|
117
117
|
const binPath = resolveBinary(verb);
|
|
118
|
+
// Ensure the platform binary is executable. npm strips the +x bit on install from
|
|
119
|
+
// files that aren't `bin`-field entries, and the platform package declares no bin
|
|
120
|
+
// field — so the staged-executable binary lands 0o644 and both spawnSync (below)
|
|
121
|
+
// and the healed sh trampoline's `exec` would EACCES / "Permission denied". The old
|
|
122
|
+
// postinstall did this chmod; doing it in the launcher covers EVERY package manager
|
|
123
|
+
// (npm strips, others may not) and runs before the heal writes a trampoline that
|
|
124
|
+
// exec's this binary. Best-effort; harmless if already executable.
|
|
125
|
+
try { fs.chmodSync(binPath, 0o755); } catch {}
|
|
118
126
|
// Self-heal the PATH entry on first POSIX call so later calls skip Node entirely.
|
|
119
127
|
healPathEntry(verb, binPath);
|
|
120
128
|
// This call still runs through Node; spawn the native binary. argv0 basename of
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nubjs/nub",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.20",
|
|
4
4
|
"description": "TypeScript-first developer supertool — a fast script runner and TS runtime powered by Node.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "https://github.com/nubjs/nub",
|
|
@@ -14,13 +14,13 @@
|
|
|
14
14
|
"platform.js"
|
|
15
15
|
],
|
|
16
16
|
"optionalDependencies": {
|
|
17
|
-
"@nubjs/nub-darwin-arm64": "0.0.
|
|
18
|
-
"@nubjs/nub-darwin-x64": "0.0.
|
|
19
|
-
"@nubjs/nub-linux-x64": "0.0.
|
|
20
|
-
"@nubjs/nub-linux-x64-musl": "0.0.
|
|
21
|
-
"@nubjs/nub-linux-arm64": "0.0.
|
|
22
|
-
"@nubjs/nub-linux-arm64-musl": "0.0.
|
|
23
|
-
"@nubjs/nub-win32-x64": "0.0.
|
|
24
|
-
"@nubjs/nub-win32-arm64": "0.0.
|
|
17
|
+
"@nubjs/nub-darwin-arm64": "0.0.20",
|
|
18
|
+
"@nubjs/nub-darwin-x64": "0.0.20",
|
|
19
|
+
"@nubjs/nub-linux-x64": "0.0.20",
|
|
20
|
+
"@nubjs/nub-linux-x64-musl": "0.0.20",
|
|
21
|
+
"@nubjs/nub-linux-arm64": "0.0.20",
|
|
22
|
+
"@nubjs/nub-linux-arm64-musl": "0.0.20",
|
|
23
|
+
"@nubjs/nub-win32-x64": "0.0.20",
|
|
24
|
+
"@nubjs/nub-win32-arm64": "0.0.20"
|
|
25
25
|
}
|
|
26
26
|
}
|