diff --git a/pmf-suspend b/pmf-suspend index fb65645..9700f24 100644 --- a/pmf-suspend +++ b/pmf-suspend @@ -1,5 +1,8 @@ #!/bin/bash +# Set user to lock +COMPUTER_USER="stina" + # Run a simulation of the program. Does not lock nor suspend the system. SIMULATION=0 @@ -9,17 +12,13 @@ PARAM_3=$3 PARAM_4=$4 -# Set user to lock -COMPUTER_USER="stina" - # Help if [[ $1 == "help" || $1 == "--help" || $1 == "" ]]; then echo -e "Usage: - pmf-suspend now|--help|--simulation|0-9[ 0-9[ 0-9]] - - pmf-suspend now Lock the screen and suspend system - pmf-suspend --help|help Show this message - pmf-suspend --simulation Run a simulation of the program, execute nothing. + pmf-suspend now|help|simulation|0-9[ 0-9[ 0-9]] + pmf-suspend now Lock the screen and suspend system. + pmf-suspend simulation Run a simulation of the program, execute nothing. + pmf-suspend help|--help Show this message pmf-suspend 1 2 3 Timer will be set to 1s, 2m, 3h pmf-suspend 0 30 Timer will be set to 30 mintues @@ -34,6 +33,9 @@ The command pmf-suspend stands for Power Manager (Fix) suspend. In order to suspend the system this program must be run as root. + + You need to change the 'COMPUTER_USER' variable in this script in + order to be able to lock your computer while running as root. "; exit 1