Skip to content

Commit ee4ba27

Browse files
committed
Fix after install script for Debian
1 parent aedef13 commit ee4ba27

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

build/linux/after-install.tpl

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/bin/bash
2+
# Reference the official tpl script at https://github.com/electron-userland/electron-builder/blob/master/packages/app-builder-lib/templates/linux/after-install.tpl
3+
4+
# Link to the binary
5+
ln -sf "/opt/${productFilename}/${executable}" "/usr/bin/${executable}"
6+
7+
# SUID chrome-sandbox for Electron 5+
8+
chmod 4755 "/opt/${productFilename}/chrome-sandbox" || true
9+
10+
update-mime-database /usr/share/mime || true
11+
update-desktop-database /usr/share/applications || true

electron-builder.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ linux:
3636
- deb
3737
maintainer: electronjs.org
3838
category: Utility
39+
deb:
40+
afterInstall: build/linux/after-install.tpl
3941
appImage:
4042
artifactName: ${name}-${version}.${ext}
4143
npmRebuild: false

0 commit comments

Comments
 (0)