Skip to content

Commit e33af24

Browse files
committed
Add sudo warning
1 parent 523e168 commit e33af24

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

unit6_fix_sp24.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,14 @@ bold='\033[1m'
2020
## Script developed by rollingcoconut and sarcb
2121
##########################################
2222

23-
echo "THIS SCRIPT IS UNDER DEVELOPMENT. PLEASE DO NOT USE IT YET"
24-
2523
echo "[UNIT 6 LAB/PROJECT SPRING 2024 FIX] Starting script..."
2624

25+
# Check if the user is root
26+
if [ "$EUID" -ne 0 ]; then
27+
echo -e "${red}[ERROR]${none} Please run using sudo."
28+
exit 1
29+
fi
30+
2731
CATALYST_INSTALL_PATH=/opt/catalyst
2832
mkdir -p $CATALYST_INSTALL_PATH
2933
pushd $CATALYST_INSTALL_PATH

0 commit comments

Comments
 (0)