feat: desktop notifications via OSC 9#349
Open
jheronimus wants to merge 1 commit into
Open
Conversation
jheronimus
force-pushed
the
feat/notifications
branch
3 times, most recently
from
July 16, 2026 20:16
f7ad69c to
b22ef22
Compare
Fires a desktop notification when the agent finishes its turn and the terminal is not focused. Uses OSC 9 escape sequences — supported by Ghostty, iTerm2, Kitty, WezTerm, and Warp. A \r\x1b[K cleanup sequence appended after the notification prevents text leakage on terminals without OSC 9 support (e.g. macOS Terminal.app). Enabled via 'notifications: true' in ~/.tau/tui.json (default: off). Suppressed via Textual's App.app_focus when the terminal is frontmost.
jheronimus
force-pushed
the
feat/notifications
branch
from
July 18, 2026 12:57
b22ef22 to
7892798
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a minimalistic notifications feature. All it does is let the user know when the agent has ended its turn and waits for new input.
It uses OSC 9, so it is cross platform and should work with terminals that support it (Ghostty, iTerm2, Kitty, WezTerm, Warp). It is safe on terminals without support thanks to a
\r\x1b[Kcleanup sequence appended after the notification. It uses Textual's support of DECSET 1004 — which means the notifications only appear when the app is in the background.The feature is turned off by default, you have to add
"notifications": trueto~/.tau/tui.jsonfor it to work.New tests added, also tested it live in Ghostty: no false positives like in Antigravity (where the notification happens, but the agent isn't done yet) and no notifications when Tau is frontmost.
Also tested in Terminal.app to check that terminals without OSC 9 don't leak garbage into the UI.