summarylogtreecommitdiffstats
path: root/buttercup-desktop.sh
diff options
context:
space:
mode:
authorzxp198210052023-12-11 11:09:28 +0800
committerzxp198210052023-12-11 11:09:28 +0800
commitf0799c9fa62bd549eddbeb28be7ee57e8b1543ad (patch)
treeda69b241e7cfe1c642eaf1849018e1c8ec0aeecb /buttercup-desktop.sh
parenteb193fff2a325f53112c27a69f516f0e93d391aa (diff)
downloadaur-f0799c9fa62bd549eddbeb28be7ee57e8b1543ad.tar.gz
update to 2.23.1
Diffstat (limited to 'buttercup-desktop.sh')
-rw-r--r--buttercup-desktop.sh17
1 files changed, 9 insertions, 8 deletions
diff --git a/buttercup-desktop.sh b/buttercup-desktop.sh
index 4c16b02bd56d..2ec4412e5c4f 100644
--- a/buttercup-desktop.sh
+++ b/buttercup-desktop.sh
@@ -1,13 +1,14 @@
#!/bin/bash
-APPDIR="/usr/lib/buttercup-desktop"
+set -e
+_APPDIR="/usr/lib/@appname@"
+export PATH="${_APPDIR}:${PATH}"
export ELECTRON_IS_DEV=0
-export PATH="${APPDIR}:${PATH}"
-export LD_LIBRARY_PATH="${APPDIR}/lib:${LD_LIBRARY_PATH}"
-_ASAR="${APPDIR}/app.asar"
+export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}"
+_ASAR="${_APPDIR}/@appasar@"
if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then
- cd $APPDIR
- exec electron@electronversion@ ${_ASAR} "$@"
+ cd "${_APPDIR}"
+ exec electron@electronversion@ "${_ASAR}" "$@"
else
- cd $APPDIR
- exec electron@electronversion@ --no-sandbox "$@"
+ cd "${_APPDIR}"
+ exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@"
fi \ No newline at end of file