gm-plugkit 2.0.1260 → 2.0.1261
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/bootstrap.js +6 -1
- package/package.json +1 -1
- package/plugkit-wasm-wrapper.js +2 -1
package/bootstrap.js
CHANGED
|
@@ -23,7 +23,8 @@ function resolveWindowsExe(cmd) {
|
|
|
23
23
|
if (r.status !== 0) return cmd;
|
|
24
24
|
const lines = (r.stdout || '').split(/\r?\n/).map(l => l.trim()).filter(Boolean);
|
|
25
25
|
const exe = lines.find(l => /\.exe$/i.test(l));
|
|
26
|
-
|
|
26
|
+
const shim = lines.find(l => /\.(cmd|bat)$/i.test(l));
|
|
27
|
+
return exe || shim || cmd;
|
|
27
28
|
} catch {
|
|
28
29
|
return cmd;
|
|
29
30
|
}
|
|
@@ -300,6 +301,10 @@ async function extractNpmPackageWithRetry(destPath, version) {
|
|
|
300
301
|
lastErr = err;
|
|
301
302
|
log(`attempt ${attempt} failed: ${err.message}`);
|
|
302
303
|
obsEvent('bootstrap', 'npm.extract.attempt_failed', { package: NPM_PACKAGE, attempt, max: MAX_ATTEMPTS, err: String(err.message || err) });
|
|
304
|
+
if (err && (err.code === 'ENOENT' || /ENOENT/.test(String(err.message || '')))) {
|
|
305
|
+
log(`npm binary unresolvable (ENOENT); skipping retries, falling back`);
|
|
306
|
+
throw err;
|
|
307
|
+
}
|
|
303
308
|
if (attempt < MAX_ATTEMPTS) {
|
|
304
309
|
const wait = BACKOFF_MS[attempt - 1] || 120000;
|
|
305
310
|
log(`backing off ${wait}ms`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gm-plugkit",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1261",
|
|
4
4
|
"description": "Bootstrap and daemon-spawn tool for gm plugkit binary. Downloads the correct platform binary, verifies SHA256, and starts the spool watcher daemon. Includes plugkit-wasm-wrapper for WASM-based spool watching.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
package/plugkit-wasm-wrapper.js
CHANGED
|
@@ -541,7 +541,8 @@ function resolveWindowsExeLocal(cmd) {
|
|
|
541
541
|
if (out.status !== 0) return cmd;
|
|
542
542
|
const lines = (out.stdout || '').split(/\r?\n/).map(l => l.trim()).filter(Boolean);
|
|
543
543
|
const exe = lines.find(l => /\.exe$/i.test(l));
|
|
544
|
-
|
|
544
|
+
const shim = lines.find(l => /\.(cmd|bat)$/i.test(l));
|
|
545
|
+
return exe || shim || cmd;
|
|
545
546
|
} catch {
|
|
546
547
|
return cmd;
|
|
547
548
|
}
|