From afb2db9648c18cd727bd3e2a6e47ecf175b42202 Mon Sep 17 00:00:00 2001 From: Franscobec Date: Mon, 12 Jan 2026 14:08:55 -0500 Subject: [PATCH] Add avoid running as root blocker --- deploy-urbackup.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/deploy-urbackup.sh b/deploy-urbackup.sh index 1757568..71e68ff 100644 --- a/deploy-urbackup.sh +++ b/deploy-urbackup.sh @@ -1,4 +1,11 @@ #!/bin/bash +#avoid running as root +NO_FORMAT="\e[0m" +C_RED="\e[38;5;9m" +if [ "$UID" = 0 ]; then + echo -e "${C_RED}This script cannot be run as root.${NO_FORMAT}" + exit 1 +fi #update local update db yay -Syy #install outdated dep from provision server