17 Commits

Author SHA1 Message Date
Jens Krause
e2cd536079
Introduce CalendarDuration (#120)
* trait ClockDuration, CalendarDuration, tests

* make clock rendering more generic

* remove `should_blink` from `RenderClockState`

* pass less down: `mode` -> `editable_time`

* simplify `event` duration states

* remove deprecated `DirectedDuration`

* fix comments
2025-10-09 19:51:34 +02:00
Jens Krause
99032834be
(cli)! Remove --countdown-target argument (#121)
Reverts #112.

For targeting a date (past/future) a new `event` feature will be
introduced (soon).
2025-10-08 18:03:06 +02:00
Jens Krause
f79813ac6b
feat(event) Add widget (#117)
* skeleton
* make `Event` widget work
2025-10-05 21:05:14 +02:00
Jens Krause
eb376e4015
feat(args): accept years and days for --countdown (#114) 2025-10-01 15:26:02 +02:00
Jens Krause
ac2863cebc
upgrade deps (#113)
* run `cargo upgrade`

```sh
❯ cargo upgrade
    Checking timr-tui's dependencies
name               old req compatible latest new req
====               ======= ========== ====== =======
tokio              1.45.1  1.47.1     1.47.1 1.47.1
tokio-util         0.7.15  0.7.16     0.7.16 0.7.16
tracing-subscriber 0.3.19  0.3.20     0.3.20 0.3.20
clap               4.5.40  4.5.48     4.5.48 4.5.48
time               0.3.41  0.3.44     0.3.44 0.3.44
thiserror          2.0.12  2.0.17     2.0.17 2.0.17
   Upgrading recursive dependencies
     Locking 0 packages to latest Rust 1.90.0 compatible versions
note: pass `--verbose` to see 2 unchanged dependencies behind latest
note: Re-run with `--incompatible` to upgrade incompatible version requirements
note: Re-run with `--verbose` to show more dependencies
  incompatible: 4 packages
  latest: 8 packages
```

* fix(duration) `test_parse_duration_by_time` panics
2025-10-01 13:34:20 +02:00
Jens Krause
3f4acec9f5
feat(args): parse countdown by given time (past or future) (#112)
* feat(args): parse `countdown` by time

* fix lint

No `Default` for `AppTime` needed...

* app: pass `countdown_until` down

* fix `parse_duration_by_time` and `parse_duration`

to handle different formats they support

* fix(countdown): percentage panics

`Duration::ZERO` needs to be considered

* `DirectedDuration`

* fix comment

* rename arg: `countdown-target`

* `ss`->`mm`, fix formats, update README

* alias `--ct`
2025-10-01 12:40:27 +02:00
Jens Krause
cb6c2d5142
feat(edit): 10x up/down (#110)
* feat(edit): 10x up/down

* fix `MAX_DURATION` (decisecond)

* footer: add `edit 10x` keybindings

* README: update keybindings
2025-09-30 12:38:25 +02:00
jk
d5bf7f32a6 feat(timer|c-dwn): show/edit years + days 2025-09-28 10:40:34 +02:00
jk
9ff65e5c8e feat(duration): days and years 2025-09-28 10:40:34 +02:00
Jens Krause
901cf69472
feat(screen): LocalTime (#90) 2025-08-30 21:48:56 +02:00
jk
5bc37f005f
lint again
in addition to #88, especially 78f5269
2025-06-28 11:49:21 +02:00
Jens Krause
3d9b235f12
Rust 1.85.0 + Rust 2024 Edition (#68)
- Add `rust-toolchain.toml`
- Refactor `flake` to consider `rust-toolchain.toml`, especially Rust version
- `just`: Add run-sound command
- Ignore sound files
- Format
2025-02-25 20:30:20 +01:00
Jens Krause
6d2bf5ac09
Edit countdown by local time (#49) 2025-01-13 18:44:56 +01:00
Jens Krause
c8af76c9e5
feat(countdown): rocket countdown (#45) 2025-01-08 18:52:18 +01:00
jk
e4dcf61153
move parse_duration into duration module 2025-01-01 18:23:19 +01:00
Jens K.
ca81094a36
fix edits (#26)
incl. editing `deciseconds` + more tests
2024-12-26 20:03:22 +01:00
jk
ed7c17caf9
DurationEx 2024-12-26 15:14:41 +01:00