A lightweight macOS menubar app that tracks your daily work hours. No accounts, no projects, no cloud — just a simple timer that shows how long you've been working today.
- Displays elapsed work time in the menubar (
⏱ 04:23:15) - Pauses automatically when you lock the screen or Mac goes to sleep
- Resumes automatically when you unlock or wake up
- Manual pause/resume — pause the timer for personal breaks (icon changes to
⏸) - Adjust time — correct the tracked time via a dialog (e.g. forgot to pause for lunch)
- Weekly stats — see extra hours per week: overtime beyond 7.5h on workdays + all weekend hours
- Global stats — all-time totals: total tracked time and cumulative balance across your full history
- Persists across logout/login and app restarts
- Resets automatically each new day
- Keeps daily history — view the last 14 days from the menubar
- Color indicators: orange at 8h, red at 10h
- Single Swift file, no dependencies
Requires Xcode Command Line Tools (xcode-select --install).
git clone https://github.com/MikhailKuklin/WorkClock.git
cd WorkClock
make installgit clone https://github.com/MikhailKuklin/WorkClock.git
cd WorkClock
swiftc -o WorkClock WorkClock.swift -framework Cocoa
mkdir -p WorkClock.app/Contents/MacOS
cp WorkClock WorkClock.app/Contents/MacOS/
cp Info.plist WorkClock.app/Contents/
cp -r WorkClock.app /Applications/
open /Applications/WorkClock.appCopy the launch agent to auto-start WorkClock on login:
make autostartOr manually:
cp com.workclock.plist ~/Library/LaunchAgents/
launchctl load ~/Library/LaunchAgents/com.workclock.plist- The timer starts when the app launches and counts your active (unlocked) time
- Click the menubar icon for options:
- Pause/Resume — manually pause for breaks; screen unlock won't auto-resume while paused
- Adjust Time… — set today's tracked time to any value (HH:MM format). Useful when you forgot to pause for a break or started the app late
- History — view daily totals for the last 14 days. Click any entry to adjust its time. Use Add Past Day… to add a missing day
- Weekly Stats — view extra hours per week (last 8 weeks). Extra hours = time worked beyond 7.5h on weekdays + all time on weekends. Shown in green when positive
- Global Stats — all-time summary across your full history: total tracked time and cumulative balance (same overtime rule as Weekly Stats) shown green when positive, red when negative
- Reset — reset today's timer to zero
- Quit — stop the app
| File | Purpose |
|---|---|
~/.workclock_state |
Current day's accumulated time |
~/.workclock_history |
Daily totals log (YYYY-MM-DD HH:MM:SS) |
make uninstallOr manually:
pkill -f WorkClock.app
launchctl unload ~/Library/LaunchAgents/com.workclock.plist
rm ~/Library/LaunchAgents/com.workclock.plist
rm -rf /Applications/WorkClock.app
rm ~/.workclock_state ~/.workclock_historyMIT