-
-
Save anonymous/7913c26c8e587a4bab9e to your computer and use it in GitHub Desktop.
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 | |
cd $GAMEDIR | |
while true; do | |
EDITED=$(find -mmin -30 -type f | wc -l) | |
if [ "$EDITED" = 0 ]; then | |
notify-send "It's been 30 minutes, and you haven't done anything. You've lost your surfing privileges, buddy." | |
pkill chrome | |
else | |
EDITED=$(find -mmin -10 -type f | wc -l) | |
if [ "$EDITED" = 0 ]; then | |
notify-send "No files updated for 10 minutes, if you keep at it - you'll lose your surfing privileges." | |
fi | |
fi | |
sleep 60 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment