diff --git a/termux/scripts/tsu b/termux/scripts/tsu new file mode 100755 index 0000000..e4f6ab7 --- /dev/null +++ b/termux/scripts/tsu @@ -0,0 +1,6 @@ +#!/data/data/com.termux/files/usr/bin/env bash + +# Force the passing of the environment variables on LineageOS where the --preserve-environment +# option on the su binary doesn't seem to work well + +/data/data/com.termux/files/usr/bin/tsu -s "$(env | sed "s/^\([^=]\+\)=\(.*\)/\1='\2'/" | tr '\n' ' ') $(which bash)" diff --git a/termux/services/syncthing b/termux/services/syncthing index 70bbaca..dc5cbc8 100755 --- a/termux/services/syncthing +++ b/termux/services/syncthing @@ -8,7 +8,7 @@ LOGFILE="$HOME/.local/log/syncthing.log" start() { printf "Starting Syncthing: " - sudo start-stop-daemon -p "$PIDFILE" -x syncthing -S -b -N 5 -m -- -logfile="$LOGFILE" + sudo start-stop-daemon -p "$PIDFILE" -x syncthing -S -b -N 5 -m -- -logfile="$LOGFILE" -home ~/.config/syncthing echo "OK" }