File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed
Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change 11import { execSync } from 'node:child_process'
2- import { existsSync , mkdirSync } from 'node:fs'
2+ import { chmodSync , existsSync , mkdirSync } from 'node:fs'
33import { join } from 'node:path'
44
55const WIN_OUTPUT_NAME = 'Git_Commit_Analytics_win.exe'
@@ -19,10 +19,21 @@ async function buildWin() {
1919 `node -e "require('fs').copyFileSync(process.execPath, '${ OUTPUT_PATH } ')" ` ,
2020 )
2121
22+ if ( existsSync ( OUTPUT_PATH ) ) {
23+ console . log ( `✅ The file was successfully copied to: ${ OUTPUT_PATH } ` )
24+ } else {
25+ console . error ( `❌ Copy failed, file not found: ${ OUTPUT_PATH } ` )
26+ process . exit ( 1 )
27+ }
28+
2229 try {
2330 execSync ( `signtool remove /s ${ OUTPUT_PATH } ` )
2431 } catch { }
2532
33+ try {
34+ chmodSync ( OUTPUT_PATH , 0o666 )
35+ } catch { }
36+
2637 execSync (
2738 [
2839 `postject ${ OUTPUT_PATH } NODE_SEA_BLOB ${ SEA_BLOB } ` ,
@@ -47,6 +58,13 @@ async function buildMac() {
4758
4859 execSync ( `cp ${ NODE_PATH } ${ OUTPUT_PATH } ` )
4960
61+ if ( existsSync ( OUTPUT_PATH ) ) {
62+ console . log ( `✅ The file was successfully copied to: ${ OUTPUT_PATH } ` )
63+ } else {
64+ console . error ( `❌ Copy failed, file not found: ${ OUTPUT_PATH } ` )
65+ process . exit ( 1 )
66+ }
67+
5068 execSync ( `codesign --remove-signature ${ OUTPUT_PATH } ` )
5169
5270 execSync (
You can’t perform that action at this time.
0 commit comments