samg / timetrap

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

What happens when there are more than 10000 entries? #172

Closed namdnguyen closed 5 years ago

namdnguyen commented 5 years ago

I noticed that there are 4 character spaces when showing IDs in a display command before you get to a sheet name. What happens when you have 10000 or more entries? Does timetrap continue expanding the length for formatting IDs? 6 digits will be shown at 100000 and so on?

jerith666 commented 5 years ago

I haven't gotten up to six digits yet but I'm well into the five-digit range, and it seems to work okay:

$ t display --ids --start today email | head -4
Timesheet: email
Id    Day                Start      End        Duration   Notes
31378 Thu Nov 08, 2018   08:40:01 - 08:44:56   0:04:55    
31402                    15:48:07 - 15:50:43   0:02:36    

$ t --version

t: version 1.15.1  (1969-12-31 19:00:01 -0500)

(That 1969 date in the --version is because I'm on NixOS.)

namdnguyen commented 5 years ago

That's good to know. I forgot that I was viewing with the by_day formatter, too. If I run into any problems at 5 digits, I'll take a look there. Thanks for confirming! I'll close this issue.