- Isaac
- Pictures
- Internet Stuff
- Blogs
- Miscellaneous
- September 2026 - 1 post
- June 2026 - 1 post
- February 2026 - 2 posts
- December 2025 - 1 post
- November 2025 - 3 posts
- October 2025 - 1 post
- September 2025 - 2 posts
- July 2025 - 3 posts
- June 2025 - 5 posts
- May 2025 - 2 posts
- April 2025 - 3 posts
- March 2025 - 7 posts
- All Prior Years
As I wrote earlier, I use worklog to keep track of my time. I use some other scripts to help manage worklog's output, and now that I made one of the scripts work even nicer today, I figured I should post them.
I use get-time to see where I spent time on a particular day. It defaults to today, but you can give it an argument like "yesterday", "-2 days", "last thursday", etc. Now that it runs without user interaction (courtesy of expect) I have added it as a cronjob to email me at midnight with the previous day's work.
I use get-all to show me all work done since I first started using worklog. Now that I have been running it for more than a year it might not be as useful as it once was, since the average is probably different from the max and min, which might be more interesting (and maybe a future shell scripting project)
get-summary isn't intended to be run by itself, though I suppose there might be some use for it - showing you how much work you have done this month, or something like that. (Oh - I just realized that I might be using worklog differently than some people - I make a new directory for each month, and move the files at the end of the month -- and now that I have this handy expect script, I could probably automate the whole thing, and email it to Heather, so she wouldn't have to ask me to do it any more...)
Note, to get worklog to run in a cron job, you'll need to add a TERM=dumb bit, otherwise worklog won't output its time.log file at all - something to do with cron's tty not being set. Quite frustrating to figure out after spending an hour with a script that worked from the command line, but not from the cron.
Scripts: get-time get-all get-summary
Category Programming

Couldn't verify you're not a robot. Wait a moment and post your comment again.