diff options
Diffstat (limited to 'thorium-reader.sh')
-rw-r--r-- | thorium-reader.sh | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/thorium-reader.sh b/thorium-reader.sh index 2ec4412..aacd8f8 100644 --- a/thorium-reader.sh +++ b/thorium-reader.sh | |||
@@ -1,14 +1,15 @@ | |||
1 | #!/bin/bash | 1 | #!/bin/sh |
2 | set -e | 2 | set -e |
3 | _APPDIR="/usr/lib/@appname@" | 3 | _APPDIR="/usr/lib/@appname@" |
4 | _ASAR="${_APPDIR}/@appasar@" | ||
4 | export PATH="${_APPDIR}:${PATH}" | 5 | export PATH="${_APPDIR}:${PATH}" |
5 | export ELECTRON_IS_DEV=0 | ||
6 | export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}" | 6 | export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}" |
7 | _ASAR="${_APPDIR}/@appasar@" | 7 | export ELECTRON_IS_DEV=0 |
8 | export NODE_ENV=production | ||
9 | cd "${_APPDIR}" | ||
8 | if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then | 10 | if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then |
9 | cd "${_APPDIR}" | ||
10 | exec electron@electronversion@ "${_ASAR}" "$@" | 11 | exec electron@electronversion@ "${_ASAR}" "$@" |
11 | else | 12 | else |
12 | cd "${_APPDIR}" | ||
13 | exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@" | 13 | exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@" |
14 | fi \ No newline at end of file | 14 | fi |
15 | exit \ No newline at end of file | ||