eesyphp/example/bin/eesyphp.wrapper
Benjamin Renard 4f47dc056d Tpl: Add stuff to handle static files
* Move example application in example sub-directory
* Widely use App::get() instead of Config::get()
2023-02-12 00:30:36 +01:00

11 lines
187 B
Bash
Executable file

#!/bin/bash
USER=$( basename $0 )
REAL_BIN=$( realpath -L $0|sed 's/\.wrapper$//' )
if [ "$( id -u -n )" != "$USER" ]
then
sudo -u $USER $REAL_BIN $@
exit $?
fi
$REAL_BIN $@
exit $?