herozion 1.1.19 → 1.1.22
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/install.js +4 -7
- package/package.json +1 -1
package/install.js
CHANGED
|
@@ -33,11 +33,8 @@ const crypto = require("crypto");
|
|
|
33
33
|
const { execSync } = require("child_process");
|
|
34
34
|
|
|
35
35
|
const VERSION = require("./package.json").version;
|
|
36
|
-
// BINARY_VERSION may differ from VERSION when npm patches (install.js fixes, etc.)
|
|
37
|
-
// are published without new binaries. Update this when new binaries are released.
|
|
38
|
-
const BINARY_VERSION = "1.1.19";
|
|
39
36
|
const BASE_URL =
|
|
40
|
-
`https://github.com/Herozion/scanner-releases/releases/download/v${
|
|
37
|
+
`https://github.com/Herozion/scanner-releases/releases/download/v${VERSION}`;
|
|
41
38
|
|
|
42
39
|
// ── Platform detection ────────────────────────────────────────────────────────
|
|
43
40
|
|
|
@@ -128,9 +125,9 @@ async function main() {
|
|
|
128
125
|
const tmpPath = destPath + ".tmp";
|
|
129
126
|
|
|
130
127
|
// Skip download if binary already exists and matches binary version
|
|
131
|
-
const markerPath = path.join(binDir, `.version-${
|
|
128
|
+
const markerPath = path.join(binDir, `.version-${VERSION}`);
|
|
132
129
|
if (fs.existsSync(destPath) && fs.existsSync(markerPath)) {
|
|
133
|
-
console.log(`herozion: binary v${
|
|
130
|
+
console.log(`herozion: binary v${VERSION} already present, skipping download.`);
|
|
134
131
|
return;
|
|
135
132
|
}
|
|
136
133
|
|
|
@@ -142,7 +139,7 @@ async function main() {
|
|
|
142
139
|
bundledHash = (bundled[binaryName] || "").toLowerCase().trim();
|
|
143
140
|
} catch (_) {}
|
|
144
141
|
|
|
145
|
-
console.log(`herozion: downloading ${binaryName} v${
|
|
142
|
+
console.log(`herozion: downloading ${binaryName} v${VERSION}...`);
|
|
146
143
|
try {
|
|
147
144
|
// Download binary to a temporary path first, then verify checksum before placing
|
|
148
145
|
await download(url, tmpPath);
|