bitstillery
← Back to the blog

Wakamonth: hours reporting tool

Knowing where your time goes is useful. It shows which parts of the code keep eating hours, it tells you something about technical debt, and some weeks you simply need an hour report. But writing down your hours by hand takes discipline, and when work gets busy, that’s the first thing to slip. What we wanted was a stopwatch that runs by itself, and that knows which project and branch we’re working on.

What we tried first

We started with the Tempo plugin for Jira, but that meant adding hours to issues by hand, with no link to the code. When we moved to GitLab, issues and merge requests came much closer together, but GitLab has no good way to see how many hours you worked over a period. You can log time on issues, and that’s about it.

WakaTime and Wakapi

Then we found WakaTime, which works like a Fitbit for coding. A plugin in your editor quietly sends small “heartbeats” while you work, even queueing them when you’re offline, and WakaTime turns those into time per project, branch and file.

The Wakapi dashboard on a laptop

We run Wakapi, an open source server that speaks the same language as WakaTime, so the data stays with us. You can host it yourself on a small server, or use their hosted version. The editor plugins don’t know the difference.

Wakamonth

The one thing missing was a report: how many hours did I spend on what, this month? So we wrote Wakamonth. It asks the WakaTime or Wakapi API for a month of data and turns it into hours per branch, in the terminal or as an Excel sheet:

bunx @bitstillery/wakamonth -y 2024 -m 1 -p myproject report
Wakamonth report in the terminal, showing hours per branch

Keep in mind that tracked time is an estimate, not something to put on an invoice without checking. But it gives a much better picture of where the hours went than anything we wrote down from memory.

Thanks to WakaTime, to Wakapi’s creator Ferdinand Mütsch, and to the authors of the WakaTime browser extension, who added the last-branch support we needed.

Let's talk spirits & software

Curious what we do, or what we could do for you? We'd like to hear from you.