add run.sh
This commit is contained in:
parent
a58984204a
commit
52b5fc4aba
16
run.sh
Executable file
16
run.sh
Executable file
@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
scriptdir=$(dirname $(realpath $0))
|
||||
tempdir="/tmp"
|
||||
|
||||
# ============================================================
|
||||
|
||||
if [[ $EUID -eq 0 ]]; then
|
||||
echo "Running in root mode."
|
||||
sh $scriptdir/init_root.sh
|
||||
elif sudo -v; then
|
||||
echo "Running in sudo mode."
|
||||
sh $scriptdir/init_sudo.sh
|
||||
else
|
||||
echo "Please get sudo access first."
|
||||
fi
|
||||
Loading…
Reference in New Issue
Block a user