summarylogtreecommitdiffstats
path: root/switchhosts.sh
blob: 6b447eae8ef3284c1eb2846c6a853f5ee703e619 (plain)
1
2
3
4
5
6
7
8
9
10
#!/bin/bash
_ELECTRON=/usr/bin/electron24
APPDIR="/usr/lib/switchhosts"
export PATH="${APPDIR}:${PATH}"
_ASAR="${APPDIR}/app.asar"
if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then
    exec ${_ELECTRON} ${_ASAR} "$@"
else
    exec ${_ELECTRON} ${_ASAR} --no-sandbox "$@"
fi