allow emulationstation.sh to be called from any location (gets basename from $0)

This commit is contained in:
Jools Wills 2016-04-20 23:22:10 +01:00
parent 866ea49b7d
commit 23d96b6a56

View file

@ -1,8 +1,9 @@
#!/bin/sh
esdir="$(dirname $0)"
while true; do
rm -f /tmp/es-restart /tmp/es-sysrestart /tmp/es-shutdown
./emulationstation "$@"
"$esdir/emulationstation" "$@"
[ -f /tmp/es-restart ] && continue
if [ -f /tmp/es-sysrestart ]; then
rm -f /tmp/es-sysrestart