Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support OSC 9 or OSC 777;notify #1474

Closed
Hello71 opened this issue Mar 16, 2019 · 7 comments
Closed

Support OSC 9 or OSC 777;notify #1474

Hello71 opened this issue Mar 16, 2019 · 7 comments

Comments

@Hello71
Copy link

Hello71 commented Mar 16, 2019

It is useful over SSH. It was bikeshedded to death in https://bugzilla.gnome.org/show_bug.cgi?id=711059 due to excessive focus on detection of command completion, but I think the feature is good.

@kovidgoyal
Copy link
Owner

It would be helpful if you pointed to some document describing what
these escape codes are supopsed to do and what software uses them.

@Hello71
Copy link
Author

Hello71 commented Mar 16, 2019

https://chromium.googlesource.com/apps/libapps/+/master/hterm/doc/ControlSequences.md#OSC

According to that document, iTerm2 supports OSC 9 and urxvt supports OSC 777. I also read in the vte bug that Terminator supports OSC 777;notify.

@kovidgoyal
Copy link
Owner

OSC 777 seems like a urxvt specific "random command to terminal emulator for extension plugins" thing. So I am not going to implement that.

OSC 9 seems more sensible. How is the notification supposed to be encoded? as UTF-8 text? @gnachman since this scheme comes from iTerm2 could you comment? Are there any facilites for setting subtitles? Icons? Is it allowed for users to turn this off at a terminal level? Is there any detection mechanism? Is the protocol extensible in some way?

@gnachman
Copy link

It's in the session's encoding, which is UTF-8 for most people. No subtitles or icons. There is a per-profile preference to disable it. This is a really old control sequence dating to before my stewardship of iTerm; if you're going to build something new, it should be more powerful or at least have room for extension in the future.

@egmontkob
Copy link

Let's work out a specification (terminal-wg specifications 13) first.

@kovidgoyal
Copy link
Owner

I'm going to close this issue. If an when a spec is worked out, I will
be happy to implement it in kitty.

@kovidgoyal
Copy link
Owner

kovidgoyal commented Aug 21, 2020

Since, there is no movement in terminal-wg, I went ahead and implemented the OSC 99 protocol I proposed there, with some modifications based on feedback. ANd I also added support to kitty for OSC 9 for backwards compat. THe new protocol is documented in the kitty protocol extensions page. https://github.com/kovidgoyal/kitty/blob/master/docs/protocol-extensions.rst#desktop-notifications

If any one has any useful feedback on the protocol (modulo bike shedding about escape code design) feel free to comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants