feat(notifications): notify when long commands finish, with duration and exit status #37

Merged
BlackAngelTV merged 4 commits from feat/cmd-finish-notifications into main 2026-11-12 07:24:20 +01:00
4 Commits
Author SHA1 Message Date
BlackAngelTV d6bdffca10 feat(options): notify when long commands finish by default
The notification only happened if notify_on_cmd_finish was passed on the
command line or written in kitty.conf, so a fresh build looked like it had no
such feature at all. Long-running commands now notify by default once the
window loses focus; the 5 second threshold keeps short commands silent.
2026-11-11 10:59:11 +01:00
BlackAngelTV 8f8d2526ab docs: describe what the command finished notification reports
Mention the command line, the duration and the exit status in the option
documentation and record the new duration in the changelog.
2026-11-11 10:45:45 +01:00
BlackAngelTV 8708aa4101 feat(notifications): show how long a command ran when it finishes
The duration was measured to decide whether a command was long enough to
warrant a notification, but it was never shown, so the notification could only
say that the command had ended. Report it next to the exit status, formatted
in milliseconds, seconds, minutes or hours depending on the length.
2026-11-11 10:45:45 +01:00
BlackAngelTV 3791cdc024 fix(notifications): report the parsed exit status of finished commands
A shell that ends a command with a bare OSC 133;D leaves the raw status string
empty, so the notification said "finished with status: ." and the command action
got an empty %s. Use the status already parsed for the event instead.
2026-11-11 10:45:18 +01:00