Merge pull request #1 from t-nelis/root-check

Improve "running as root" check
This commit is contained in:
Stéphane Lesimple 2018-01-08 08:58:21 +01:00 committed by GitHub
commit 5c14384e15
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -256,7 +256,7 @@ fi
/bin/echo
if [ "$USER" != root ]; then
if [ "$(id -u)" -ne 0 ]; then
/bin/echo "Note that you should launch this script with root privileges to get accurate information"
/bin/echo "You can try the following command: sudo $0"
fi