This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
ROOT_UID=0 | |
SUCCESS=0 | |
E_USEREXISTS=70 | |
# Run as root, of course. (this might not be necessary, because we have to run the script somehow with root anyway) | |
if [ "$UID" -ne "$ROOT_UID" ] | |
then | |
echo "Must be root to run this script." | |
exit $E_NOTROOT |