rTimelogger is a cross-platform command-line time tracking tool written in Rust. It tracks working time using IN / OUT events, supports multiple locations, lunch rules, working gaps, and computes expected exit time and daily surplus accurately.
๐ Whatโs new in v0.8.0
Version 0.8.0 is the first stable release based on the new timeline engine.
โ Timeline engine (stable)
-
Unlimited IN / OUT pairs per day
-
Deterministic reconstruction: events โ timeline โ pairs
-
Correct handling of:
- lunch breaks
- working gaps
- multi-position days
-
Legacy
work_sessionslogic fully retired
๐ Working gap support
Time between pairs can be explicitly controlled:
--work-gapโ gap counts as working time--no-work-gapโ gap does not count as working time
Features:
-
Stored in the database
-
Editable retroactively
-
Fully reflected in:
- worked time
- expected exit
- surplus
Visual indicators:
- ๐ working gap
- โ๏ธ non-working gap
๐งฎ Accurate calculations
-
Worked time:
- sum of all pairs
- minus non-working gaps
- plus working gaps only when marked
-
Expected exit:
- based on first IN
- configured minimum working time
- lunch rules and lunch window
-
Surplus is correct in all multi-pair scenarios
๐ง Consistency improvements
-
OUTevents inherit position fromINwhen--posis omitted -
Pair details show the actual position of each pair
-
Clean event listing:
- no duplicated dates
- aligned output
-
Unified CLI message system:
- โน๏ธ info ยท โ ๏ธ warning ยท โ error ยท โ success
โจ Features
-
Event-based time tracking (IN / OUT)
-
Multiple working positions:
OOfficeRRemoteCClient / On-siteHHolidayMMixed
-
Automatic calculation of:
- expected exit
- daily surplus
-
Configurable lunch rules
-
Event mode with:
- pairing
- per-pair summaries
- JSON output
- unmatched detection
-
Internal audit log
-
Safe database migrations with automatic backups
-
Cross-platform (Linux, macOS, Windows)
๐ฆ Installation
๐ฆ Cargo (recommended)
๐ง Arch Linux (AUR)
# or
๐บ Homebrew (macOS / Linux)
โ๏ธ Configuration
Initialize configuration and database:
Example rtimelogger.conf:
database: /home/user/.rtimelogger/rtimelogger.sqlite
default_position: O
min_work_duration: 8h
min_duration_lunch_break: 30
max_duration_lunch_break: 90
separator_char: "-"
show_weekday: None # None | Short | Medium | Long
Override database path at runtime:
๐งญ Main commands overview
| Command | Description |
|---|---|
init |
Initialize DB and config |
add |
Add or edit IN / OUT events |
list |
Show sessions, events, or details |
del |
Delete events or pairs (with confirmation) |
backup |
Backup database (optional compression) |
export |
Export data (CSV / JSON / XLSX / PDF) |
db |
Database utilities |
config |
Manage configuration file |
log |
Show internal audit log |
โ Add work sessions โ rtimelogger add
Examples:
๐ Listing sessions โ rtimelogger list
The list command displays saved work sessions, supporting multiple layouts and levels of detail.
Basic usage:
Shows the sessions for the current month using the default tabular layout.
๐ Supported periods
๐ Weekday display
The weekday is shown inside the date column, using the format:
YYYY-MM-DD (Mo)
YYYY-MM-DD (Monday)
The format is controlled by the show_weekday configuration option:
| Value | Output example |
|---|---|
none |
2025-12-19 |
short |
2025-12-19 (Mo) |
medium |
2025-12-19 (Mon) |
long |
2025-12-19 (Monday) |
๐ Standard output
Example:
DATE (WD) | POSITION | IN | LNCH | OUT | TGT | ฮWORK
---------------------------------------------------------------------------
2025-12-19 (Fr) | Remote | 08:55 | 00:30 | 18:27 | 17:01 | -02h04m
Columns explained:
- IN โ first check-in of the day
- LNCH โ total lunch break duration
- OUT โ last check-out
- TGT โ planned exit time (minimum required work time)
- ฮWORK โ worked surplus or deficit
๐งพ Pair details (--details)
Displays the individual IN/OUT pairs for the selected day. It is available only for single-day periods or
--today.
Output example:
DETAILS
PAIR | IN | OUT | WORKED | LUNCH | POSITION | WG
------------------------------------------------------
1 | 08:55 | 09:37 | 00h42m | 0m | Remote |
2 | 13:07 | 18:27 | 04h50m | 30m | Remote |
Columns explained:
- PAIR โ pair index
- IN / OUT โ timestamps for the pair
- WORKED โ worked time for the pair
- LUNCH โ lunch break for the pair
- POSITION โ position for the pair
- WG โ working gap indicator (๐ for working gap, โ๏ธ for non-working gap)
๐ฆ Compact view (--compact)
Shows a condensed, single-line-per-day view, suitable for long periods.
Example:
DATE (WD) | POSITION | IN / LNCH / OUT | TGT | ฮWORK
--------------------------------------------------------------------
2025-12-19 (Fr) | Remote | 08:55 / 00:30 / 18:27 | 17:01 | ฮ -02h04m
2025-12-22 (Mo) | Holiday | --:-- / --:-- / --:-- | --:-- | ฮ -
Characteristics:
- compact horizontal layout
- weekday forced to short format
- no pair details
โ ๏ธ
--compactcannot be combined with--details
Events listing (--events)
Displays the raw IN / OUT events for the selected day.
Output example:
EVENTS:
Date Time | Type | Lunch | Position | Source | Pair | Work Gap
----------------------------------------------------------------------------------------
โ 2025-12-19 08:55 | in | lunch 0 min | Remote | cli | 1 |
09:37 | out | lunch 0 min | Remote | cli | 1 |
13:07 | in | lunch 0 min | Remote | cli | 2 |
18:27 | out | lunch 30 min | Remote | cli | 2 |
๐๏ธ Holiday days
Days marked as Holiday:
- display no time values (--:--)
- do not affect surplus calculations
- are rendered as neutral rows
โ Period total
At the end of the output, a cumulative total is always displayed:
ฮฃ Total ฮWORK: +02h04m
The total accounts for:
- lunch breaks
- work gaps
- holidays (neutral contribution)
๐ข JSON output (--json)
Outputs the data in JSON format for easy integration with other tools or scripts.
๐๏ธ Delete data โ rtimelogger del
All deletions require confirmation and automatically reindex pairs.
๐พ Backup database โ rtimelogger backup
- confirmation before overwrite
- ZIP on Windows
- TAR.GZ on Linux/macOS
๐ค Export data โ rtimelogger export
Supported formats:
csvjsonxlsxpdf
Output path must be absolute.
๐๏ธ Database utilities โ rtimelogger db
โ๏ธ Configuration management โ rtimelogger config
Missing fields are added automatically with defaults.
๐ Internal audit log โ rtimelogger log
Shows timestamped internal operations (add, del, migrate, backup, โฆ).
๐ Upgrading from older versions
If you are upgrading from 0.7.x or earlier, read:
โก๏ธ UPGRADE-0.7-to-0.8.md
This document explains:
- schema changes
- migration behavior
- removed legacy features
- important behavioral differences
๐ Documentation
- ๐ CHANGELOG.md
- ๐ UPGRADE-0.7-to-0.8.md
๐ License
MIT License โ see LICENSE.