Skip to content

Commit 06718c5

Browse files
committed
Hopefully fix Windows shortcuts
* Revert element-hq@79d1643 as it seems to break shortcuts altogether * Update electron-builder (and add the squirrel windows package that the newer version now requires: it's been split out). This uses a newer version of squirrel which has some fixes for shortcuts. I'm unsure exactly what was going wrong originally in element-hq#2775 but #79d1643 seems to break shortcut creation as far as I can see.
1 parent 6a1af89 commit 06718c5

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

‎electron/src/squirrelhooks.js‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,12 @@ const spawn = require('child_process').spawn;
33
const app = require('electron').app;
44

55
function run_update_exe(args, done) {
6-
const updateExe = path.resolve(path.dirname(process.execPath), 'Update.exe');
6+
// Invokes Squirrel's Update.exe which will do things for us like create shortcuts
7+
// Note that there's an Update.exe in the app-x.x.x directory and one in the parent
8+
// directory: we need to run the one in the parent directory, because it discovers
9+
// information about the app by inspecting the directory it's run from.
10+
const updateExe = path.resolve(path.dirname(process.execPath), '..', 'Update.exe');
11+
console.log('Spawning `%s` with args `%s`', updateExe, args);
712
spawn(updateExe, args, {
813
detached: true
914
}).on('close', done);

‎package.json‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@
9494
"chokidar": "^1.6.1",
9595
"cpx": "^1.3.2",
9696
"css-raw-loader": "^0.1.1",
97-
"electron-builder": "^10.4.1",
97+
"electron-builder": "^11.2.4",
98+
"electron-builder-squirrel-windows": "^11.2.1",
9899
"emojione": "^2.2.3",
99100
"expect": "^1.16.0",
100101
"fs-extra": "^0.30.0",

0 commit comments

Comments
 (0)