Skip to content

Commit 4ba9c16

Browse files
committed
Fixed GUI and added JSON for config
GUI supports 25 character names GUI supports 5 digit hour numbers, enough to store 11 years straight! Config file is formatted JSON instead of text
1 parent d5b734c commit 4ba9c16

File tree

4 files changed

+374
-362
lines changed

4 files changed

+374
-362
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ times/
22
!times/.gitkeep
33
usernameFile.txt
44
opts.txt
5+
opts.json
56

67
##### ---------- PYTHON GITIGNORE ---------- #####
78

autoClockout.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# auto clock out at midnight or whatever
2-
from os import listdir, environ
2+
from os import environ, listdir
33
from time import sleep, strftime
44

55
from guiType import refreshListboxes
6-
from ioServ import loadOpts, calcSlackTimeString
6+
from ioServ import calcSlackTimeString, loadOpts
77

88
try:
99
from slacker import Slacker
@@ -31,7 +31,8 @@ def main():
3131
if strftime("%w") == "0" and currenttime == "00:00:00" and slackapiExists:
3232
print("sending to slack!")
3333
timeString = calcSlackTimeString()
34-
slackapi.chat.post_message("#programming_timeclock", timeString, as_user=True)
34+
slackapi.chat.post_message(
35+
"#programming_timeclock", timeString, as_user=True)
3536

3637
if currenttime == opts["autoClockOut"]:
3738
for item in listdir(path=opts["pathTime"]):

0 commit comments

Comments
 (0)