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

Why Fish not allowed to bind Ctrl + backslash? #9234

Closed
netherstar opened this issue Sep 25, 2022 · 3 comments
Closed

Why Fish not allowed to bind Ctrl + backslash? #9234

netherstar opened this issue Sep 25, 2022 · 3 comments

Comments

@netherstar
Copy link

netherstar commented Sep 25, 2022

i tried to bind Ctrl + backslash but it doesn't work
bind \c\\ "do somethings"
also using fish_key_read with ctrl + backslash show nothing.

@faho
Copy link
Member

faho commented Sep 25, 2022

If fish_key_reader shows nothing, that means the terminal sends nothing, and so fish can't tell that you've pressed it.

This is a limitation we can't do anything about. See https://fishshell.com/docs/current/cmds/bind.html#terminal-limitations

@faho faho closed this as completed Sep 25, 2022
@faho faho added the upstream we can't fix it label Sep 25, 2022
@netherstar
Copy link
Author

netherstar commented Sep 25, 2022

but i can map Ctrl + \ in vim and it's work perfect.
I'm using Windows Terminal

@faho faho reopened this Sep 25, 2022
@faho
Copy link
Member

faho commented Sep 25, 2022

Okay, found it: It's typically bound in the terminal to sending the QUIT signal. It appears vim disables this, we can as well.

(one slight hiccup here is that \c\ is an awkward escape to give to a bind command, so I'm gonna make it so fish_key_reader gives it to you in hex form - \x1c).

@faho faho added enhancement and removed upstream we can't fix it labels Sep 25, 2022
@faho faho added this to the fish 3.6.0 milestone Sep 25, 2022
@faho faho closed this as completed in ccca5b5 Sep 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants