Skip to content
This repository was archived by the owner on Jun 15, 2023. It is now read-only.

Commit 3a477ee

Browse files
committed
tweak to support m1
1 parent 61651e2 commit 3a477ee

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

snapshot.js

+13-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//@ts-check
12
var child = require("child_process");
23
var fs = require("fs");
34
var os = require("os");
@@ -17,9 +18,20 @@ function build() {
1718
}
1819
}
1920
exports.build = build;
21+
22+
/**
23+
* @type{string}
24+
*/
25+
var dst;
26+
if (ext === 'darwin') {
27+
dst = path.join(__dirname, "..", process.platform + process.arch, `ninja.exe`);
28+
} else {
29+
dst = path.join(__dirname, "..", ext, `ninja.exe`);
30+
}
31+
2032
if (require.main === module) {
2133
build();
2234
var src = path.join(__dirname, `ninja${ext === "win32" ? ".exe" : ""}`);
23-
var dst = path.join(__dirname, "..", ext, `ninja.exe`);
35+
2436
fs.copyFileSync(src, dst);
2537
}

0 commit comments

Comments
 (0)