samg / timetrap

Simple command line timetracker
http://rubygems.org/gems/timetrap
Other
1.48k stars 115 forks source link

Adding an entry retrospectively #134

Open jakubgarfield opened 8 years ago

jakubgarfield commented 8 years ago

Is there a way to add an entry retrospectively? Something that would cover these 3 commands.

t in Description of the task
t out
t e -s 10:00 -e 11:00

Easy to wrap them in the script, but just asking if I'm not missing out on some feature.

samg commented 8 years ago

There's currently no way to do this with a single timetrap command. You could "simplify" this to two commands along the lines of:

t i -a 10:00 Description of task
t o -a 11:00

There's also the t backend command which gives you a raw SQL console, though that may not be particularly convenient.

Probably your best bet is defining a shell alias or function (or script) to do this if it's a common task for you. I could imagine t edit being changed to take an additional flag that would cause it to create a new entry instead of modifying a previous one. Something along the lines of t edit --new -s10:00 -e11:00 Description of the task.

animetrics commented 7 years ago

I think the main problem with the solution is that you can't do it while you are checked in. It's a common enough task that I think warrants an extension.