1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 05:47:35 +00:00

Meta: Add error message when running serenity.sh as root

It's not a good idea, and it causes countless issues for people who
do so and then try to run without root later.
This commit is contained in:
Andrew Kaster 2022-05-30 23:35:59 -06:00 committed by Linus Groh
parent 808855d763
commit e46a00f0c0

View file

@ -82,6 +82,10 @@ if [ "$CMD" = "help" ]; then
exit 0
fi
if [ "$(id -u)" -eq 0 ]; then
die "Do not run serenity.sh as root, your Build directory will become root-owned"
fi
if [ -n "$1" ]; then
TARGET="$1"; shift
else