samg / timetrap

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

Allow external note editor for old entries. #145

Closed patrickdavey closed 7 years ago

patrickdavey commented 7 years ago

At the moment, if you're using the note_editor functionality, if you try to edit an old note by it's id (e.g. t edit --id 76) then no editor will be launched.

This PR makes it so that you can edit a note by it's ID and it will launch an editor. It will only launch the external editor if you are either running an empty command t edit or when you're launching the edit against an id (t edit --id 76), this means that if you're editing the start time for example, that the external editor will not be launched, which is the existing behaviour and probably what's the best default.

samg commented 7 years ago

Looks like a good improvement. Thanks!

patrickdavey commented 7 years ago

Thanks @samg glad you like it. Would it be possible to get a new version of the gem released with it (or what's the best way to pull it in, locally I've just generated the gem myself)

samg commented 7 years ago

I just pushed 1.13.0 which has this in it.