Skip to content

Commit

Permalink
Merge pull request #375 from NeurodataWithoutBorders/fix-win-script-path
Browse files Browse the repository at this point in the history
Fix Windows Script Path
  • Loading branch information
CodyCBakerPhD authored Sep 20, 2023
2 parents 5503e20 + 6015ccb commit bc661a0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ const pythonIsClosed = (err = globals.python.latestError) => {
* @returns {boolean} True if the app is packaged, false if it is running from a dev version.
*/
const getPackagedPath = () => {
const scriptPath = isWindows ? path.join(__dirname, PY_FLASK_DIST_FOLDER, PYFLASK_BUILD_SUBFOLDER_NAME, `${PYINSTALLER_NAME}.exe`) : path.join(process.resourcesPath, PYFLASK_BUILD_SUBFOLDER_NAME, PYINSTALLER_NAME)
const scriptPath = isWindows ? path.join(__dirname, PY_FLASK_DIST_FOLDER, PYINSTALLER_NAME, `${PYINSTALLER_NAME}.exe`) : path.join(process.resourcesPath, PYFLASK_BUILD_SUBFOLDER_NAME, PYINSTALLER_NAME)
if (fs.existsSync(scriptPath)) return scriptPath;
};

Expand Down

0 comments on commit bc661a0

Please sign in to comment.