Posted By

munrobaggers on 06/07/12



Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


How to check the superuser privileges

 / Published in: Bash

  1. if [ $UID -ne 0 ]; then
  2. echo "Superuser privileges are required to run this script."
  3. echo "e.g. \"sudo $0\""
  4. exit 1
  5. fi

Report this snippet  

You need to login to post a comment.