Created
September 21, 2016 20:33
-
-
Save miawgogo/6aa5d8d12b3d73995bd98b952210bd92 to your computer and use it in GitHub Desktop.
simple python alarm clock
This file contains hidden or 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
# A simple python alarm clock | |
# example: python alarm.py [time in 24h with :] [music file] | |
# example: python alarm.py "6:30" "Trollenn.mp3" | |
import time, os, sys | |
ctime = time.strftime("%H:%M") | |
print(ctime) | |
while ctime != sys.argv[1]: | |
ctime = time.strftime("%H,%M") | |
os.system("mpv " + sys.argv[2]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment