Files
q-tools/aerofs/aerofs-pause
2013-11-05 20:09:42 +02:00

18 lines
295 B
Bash
Executable File

#!/bin/bash
if [ -z "$1" ]
then timeout=60
else timeout=$1
fi
aerofs-sh pause
for (( i=0; i<$timeout; i++ ))
do echo -e '\033[1A'
left=$(( $timeout - $i ))
read -t 60 -n 1 -s -p "Pausing for $left min Abort? [anykey] " input
if [ $? -eq 0 ]
then break
fi
done
aerofs-sh resume