From 221d53e8b03bf55bf35f2c6c5c4c9a762f7df31b Mon Sep 17 00:00:00 2001 From: zxp19821005 Date: Thu, 14 Mar 2024 17:53:50 +0800 Subject: fix errors --- thorium-reader.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'thorium-reader.sh') diff --git a/thorium-reader.sh b/thorium-reader.sh index f9ced14..7ddcaab 100644 --- a/thorium-reader.sh +++ b/thorium-reader.sh @@ -1,14 +1,16 @@ -#!/bin/sh +#!/bin/bash set -e _APPDIR="/usr/lib/@appname@" _RUNNAME="${_APPDIR}/@runname@" +_OPTIONS="@options@" export PATH="${_APPDIR}:${PATH}" export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}" export ELECTRON_IS_DEV=0 +export ELECTRON_FORCE_IS_PACKAGED=true export NODE_ENV=production cd "${_APPDIR}" if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then - exec electron@electronversion@ "${_RUNNAME}" "$@" || exit $? + exec electron@electronversion@ "${_RUNNAME}" "${_OPTIONS}" "$@" || exit $? else - exec electron@electronversion@ "${_RUNNAME}" --no-sandbox "$@" || exit $? + exec electron@electronversion@ "${_RUNNAME}" "${_OPTIONS}" --no-sandbox "$@" || exit $? fi \ No newline at end of file -- cgit v1.2.3-70-g09d2