diff --git a/packages/main/src/modules/bin.ts b/packages/main/src/modules/bin.ts index 21363f1e..af65a6e8 100644 --- a/packages/main/src/modules/bin.ts +++ b/packages/main/src/modules/bin.ts @@ -126,13 +126,13 @@ export async function install() { cwd: APP_UNPACKED_PATH, workspace, }); - await npmInstall.waitFor(/added \d+ packages/); // wait for successs message, because when the user quits the app while installing, npm exits gracefully with an exit code=0; + await npmInstall.waitFor(/added \d+ packages|up to date/); // wait for successs message, because when the user quits the app while installing, npm exits gracefully with an exit code=0; // save the current version to the registry log.info('[Install] Writing current version to the registry'); await fs.writeFile( path.join(APP_UNPACKED_PATH, 'version.json'), - JSON.stringify({ version: import.meta.env.VITE_APP_VERSION }), + JSON.stringify({ version: app.getVersion() }), ); } else { log.info('[Install] Skipping installation of node_modules because it is up to date');