aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryson Steck <steck.bryson@gmail.com>2022-06-04 17:10:41 -0600
committerBryson Steck <steck.bryson@gmail.com>2022-06-04 17:10:41 -0600
commit7d5d117760c3c289351c6dbcdca390d1bf65dd90 (patch)
tree29231329f1214e32b25a3e68a96ec0d607bf7056
parent93b54e8412e727bb8f524871fbc482ae56ffd0a2 (diff)
downloadriibalanced-patcher-7d5d117760c3c289351c6dbcdca390d1bf65dd90.tar
riibalanced-patcher-7d5d117760c3c289351c6dbcdca390d1bf65dd90.tar.gz
riibalanced-patcher-7d5d117760c3c289351c6dbcdca390d1bf65dd90.tar.bz2
skip sudo if root
-rwxr-xr-xpatch_iso.sh8
1 files changed, 6 insertions, 2 deletions
diff --git a/patch_iso.sh b/patch_iso.sh
index dfda8fa..a6873c0 100755
--- a/patch_iso.sh
+++ b/patch_iso.sh
@@ -78,8 +78,12 @@ if [[ ERROR -ne 0 ]]; then
fi
tar -xvf wit.tar.gz
cd wit-v*/
- echo "You will now be prompted to enter your password for sudo in order for wit to install."
- sudo ./install.sh
+ if [[ $(id -u) == 0 ]]; then
+ ./install.sh
+ else
+ echo "You will now be prompted to enter your password for sudo in order for wit to install."
+ sudo ./install.sh
+ fi
cd ..
rm -rf wit-v*/
# check if wit is installed now