warpdotdev / Warp

Warp is a modern, Rust-based terminal with AI built in so you and your team can build great software, faster.
https://warp.dev
Other
21.29k stars 371 forks source link

Support modifyOtherKeys and/or Kitty's keyboard protocol #2037

Open hovsater opened 1 year ago

hovsater commented 1 year ago

Discord username (optional)

No response

Describe the bug

While Warp is truly innovative in the terminal space I've unfortunately found it unusable due to it's lackluster support of keyboard escape sequences. I'm using dte as my main editor and unfortunately it fail to recognise most keypress combinations (e.g., C-<arrow key>, M-<arrow key>, C-S-M-<arrow key>, C-enter, C-S-enter to name a few) in Warp while it does so fine in iTerm2, wezterm, Kitty and others.

As a bare minimum, Warp should support modifyOtherKeys. It's supported by most terminal programs, including tmux with extended keys. Preferably, Warp would support Kitty's keyboard protocol in addition to modifyOtherKeys as it's definitely the way forward.

To Reproduce

$ docker run --rm -it ubuntu:latest
$ apt update && apt install -y build-essential git
$ git clone https://gitlab.com/craigbarnes/dte.git /tmp/dte
$ cd !$
$ make
$ ./dte -K

Now press different key combinations (try some of the ones mentioned above for example) and notice how they're not recognized.

Expected behaviour

I'd expect Warp to send the appropriate escape sequences.

Screenshots

No response

Operating System

MacOS

OS Version

13.0

Shell Version

GNU bash, version 5.2.2(1)-release (aarch64-apple-darwin21.6.0)

Warp Version

v0.2022.10.25.08.06.stable_03

Additional context

I opened an issue over at wezterm a while back and it has since been addressed. See https://github.com/wez/wezterm/commit/e2c658e598d713c6440302fb286a566f044f371c and https://github.com/wez/wezterm/commit/47f498768759750a0152fe6d76acb2a5b0ef7921 for details.

Here's a list of related issues.

Does this block you from using Warp daily?

Yes

Warp Internal (ignore): linear-label:b8107fdf-ba31-488d-b103-d271c89cac3e

No response

elviskahoro commented 1 year ago

@hovsater Thanks for the thorough issue. Will circle back here when we have made progress!

hovsater commented 1 year ago

@elviskahoro thank you. Appreciate it. 🙏

skiss9 commented 1 week ago

Enabling shortcuts such as cmd S to save a file in vim could be a game changer for terminal usage. Things don't have to be cryptic and unfamiliar to be powerful. It just has to be a movement where terminal emulators support these features in a good way and promote it. There are some questions about potential conflicts between the emulator app and the shell command but I think those could be solved in different clever ways.