SHARE
TWEET
Rudy
a guest
Feb 12th, 2010
36
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- #!/bin/bash
- if [ $# -ne 1 ]
- then
- echo "Usage: `basename $0` (seconds)"
- exit 65;
- fi
- if [[ $1 =~ ^[0-9]+$ ]]; then
- CNT=$1
- while [ $CNT -gt 0 ]; do
- printf "Sleeping in $CNT seconds (press Ctrl-C to abort)... \r"
- let CNT=CNT-1
- sleep 1
- done
- printf "\r\n";
- xset dpms force off
- exit 0
- else
- echo "Usage: `basename $0` (seconds)"
- exit 1;
- fi
RAW Paste Data
