diff options
author | Francis Rowe <info@gluglug.org.uk> | 2014-11-24 13:23:03 (EST) |
---|---|---|
committer | Francis Rowe <info@gluglug.org.uk> | 2014-11-24 13:23:03 (EST) |
commit | fc07688eee2eeb86ed0af2e582a1de328db6775d (patch) | |
tree | 64bdfb3ec72e49cebe52a33096609e984fb78ed6 | |
parent | 06421bb21d0f44c6aa9525886461942b3b4413d0 (diff) | |
download | libreboot-fc07688eee2eeb86ed0af2e582a1de328db6775d.zip libreboot-fc07688eee2eeb86ed0af2e582a1de328db6775d.tar.gz libreboot-fc07688eee2eeb86ed0af2e582a1de328db6775d.tar.bz2 |
powertop.trisquel6: check if user is root
-rwxr-xr-x | powertop.trisquel6 | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/powertop.trisquel6 b/powertop.trisquel6 index 2b9ee64..09a569b 100755 --- a/powertop.trisquel6 +++ b/powertop.trisquel6 @@ -20,6 +20,11 @@ set -u -e -v +if [[ $EUID -ne 0 ]]; then + echo "This script must be run as root" + exit 1 +fi + # For Trisquel 6.0 (and 6.0.1) users. # This may also work on other apt distros. |