buildscript: add color to the root warning

Signed-off-by: Johannes Kimmel <fff@bareminimum.eu>
This commit is contained in:
Johannes Kimmel 2024-01-19 22:56:53 +01:00
parent 25114a1812
commit 802aedeb43
1 changed files with 4 additions and 2 deletions

View File

@ -382,8 +382,10 @@ buildall() {
}
if [ "$(/usr/bin/id -u)" -eq 0 ]; then
echo "WARNING: buildscript is running as root"
echo "WARNING: build may fail at a later stage"
textWarn='\033[1;31m' # bold + red
textReset='\033[0m' # be a good citizen
echo -e "${textWarn}WARNING: buildscript is running as root${textReset}"
echo -e "${textWarn}WARNING: build may fail at a later stage${textReset}"
fi
if [ "$1" != "selectbsp" -a "$1" != "selectvariant" ]; then