Git commands (alt / option key bindings) not working #97
-
Git StatusCtrl+Alt+s doesn't do anything Commit hashCtrl+Alt+l clears the console Any idea why these might not be working? Thanks! macOs 10.15.6 $ bind
bind --preset \cy yank
bind --preset \ey yank-pop
bind --preset -k right forward-char
bind --preset -k left backward-char
bind --preset \e\[C forward-char
bind --preset \e\[D backward-char
bind --preset -k ppage beginning-of-history
bind --preset -k npage end-of-history
bind --preset \cx fish_clipboard_copy
bind --preset \cv fish_clipboard_paste
bind --preset \e cancel
bind --preset \t complete
bind --preset \cs pager-toggle-search
bind --preset -k btab complete-and-search
bind --preset \e\n commandline\ -i\ \\n
bind --preset \e\r commandline\ -i\ \\n
bind --preset -k down down-or-search
bind --preset -k up up-or-search
bind --preset \e\[A up-or-search
bind --preset \e\[B down-or-search
bind --preset -k sright forward-bigword
bind --preset -k sleft backward-bigword
bind --preset \e\eOC nextd-or-forward-word
bind --preset \e\eOD prevd-or-backward-word
bind --preset \e\e\[C nextd-or-forward-word
bind --preset \e\e\[D prevd-or-backward-word
bind --preset \eO3C nextd-or-forward-word
bind --preset \eO3D prevd-or-backward-word
bind --preset \e\[3C nextd-or-forward-word
bind --preset \e\[3D prevd-or-backward-word
bind --preset \e\[1\;3C nextd-or-forward-word
bind --preset \e\[1\;3D prevd-or-backward-word
bind --preset \e\[1\;9C nextd-or-forward-word
bind --preset \e\[1\;9D prevd-or-backward-word
bind --preset \e\eOA history-token-search-backward
bind --preset \e\eOB history-token-search-forward
bind --preset \e\e\[A history-token-search-backward
bind --preset \e\e\[B history-token-search-forward
bind --preset \eO3A history-token-search-backward
bind --preset \eO3B history-token-search-forward
bind --preset \e\[3A history-token-search-backward
bind --preset \e\[3B history-token-search-forward
bind --preset \e\[1\;3A history-token-search-backward
bind --preset \e\[1\;3B history-token-search-forward
bind --preset \e\[1\;9A history-token-search-backward
bind --preset \e\[1\;9B history-token-search-forward
bind --preset \e. history-token-search-backward
bind --preset \el __fish_list_current_token
bind --preset \ew __fish_whatis_current_token
bind --preset \cl echo\ -n\ \(clear\ \|\ string\ replace\ \\e\\\[3J\ \"\"\)\;\ commandline\ -f\ repaint
bind --preset \cc __fish_cancel_commandline
bind --preset \cu backward-kill-line
bind --preset \cw backward-kill-path-component
bind --preset \e\[F end-of-line
bind --preset \e\[H beginning-of-line
bind --preset \ed kill-word
bind --preset \cd delete-or-exit
bind --preset \es __fish_prepend_sudo
bind --preset -k f1 __fish_man_page
bind --preset \eh __fish_man_page
bind --preset \ep __fish_paginate
bind --preset \e\# __fish_toggle_comment_commandline
bind --preset \ee edit_command_buffer
bind --preset \ev edit_command_buffer
bind --preset \e\[I 'emit fish_focus_in'
bind --preset \e\[O false
bind --preset \e\[\?1004h false
bind --preset -m paste \e\[200\~ __fish_start_bracketed_paste
bind --preset -M paste \e\[201\~ __fish_stop_bracketed_paste
bind --preset -M paste '' self-insert
bind --preset -M paste \r commandline\ -i\ \\n
bind --preset -M paste \' __fish_commandline_insert_escaped\ \\\'\ \$__fish_paste_quoted
bind --preset -M paste \\ __fish_commandline_insert_escaped\ \\\\\ \$__fish_paste_quoted
bind --preset -M paste ' ' self-insert-notfirst
bind --preset '' self-insert
bind --preset ' ' self-insert expand-abbr
bind --preset \n execute
bind --preset \r execute
bind --preset \ck kill-line
bind --preset -k dc delete-char
bind --preset -k backspace backward-delete-char
bind --preset � backward-delete-char
bind --preset \e\[1\~ beginning-of-line
bind --preset \e\[4\~ end-of-line
bind --preset -k home beginning-of-line
bind --preset -k end end-of-line
bind --preset -k sdc backward-delete-char
bind --preset \ca beginning-of-line
bind --preset \ce end-of-line
bind --preset \cp up-or-search
bind --preset \cn down-or-search
bind --preset \cf forward-char
bind --preset \cb backward-char
bind --preset \ct transpose-chars
bind --preset \et transpose-words
bind --preset \eu upcase-word
bind --preset \ec capitalize-word
bind --preset \e� backward-kill-word
bind --preset \e\b backward-kill-word
bind --preset \eb backward-word
bind --preset \ef forward-word
bind --preset \e\[1\;5C forward-word
bind --preset \e\[1\;5D backward-word
bind --preset \e\< beginning-of-buffer
bind --preset \e\> end-of-buffer
bind \cf __fzf_search_current_dir
bind \cr __fzf_search_history
bind \cv __fzf_search_shell_variables
bind \e\cl __fzf_search_git_log
bind \e\cs __fzf_search_git_status |
Beta Was this translation helpful? Give feedback.
Replies: 13 comments
-
But the other key bindings work? |
Beta Was this translation helpful? Give feedback.
-
Yes, other key bindings work. As far as I understand that article only remaps the ⌥→ and ⌥← combinations to replicate the cursor navigation shortcuts of macOS. This is something I had already done before: |
Beta Was this translation helpful? Give feedback.
-
For what it is worth, the git bindings also don't work with the Terminal.app |
Beta Was this translation helpful? Give feedback.
-
I've also tried quitting Karabiner-Elements.app |
Beta Was this translation helpful? Give feedback.
-
Hello again! Sorry to hear it still doesn't work. Do any of your alt keybindings work? For example: bind --preset \el __fish_list_current_token # basically runs ls
bind --preset \ev edit_command_buffer # edit command line using $EDITOR or $VISUAL
bind --preset \es __fish_prepend_sudo # prepends sudo to current command |
Beta Was this translation helpful? Give feedback.
-
They don't work either. In this case I think it is because macOS outputs alternative characters, each character corresponds to the respective shortcut ⌥l, ⌥v, and ⌥s, : $ ¬√ß Are you using Windows? |
Beta Was this translation helpful? Give feedback.
-
I'm on macOS and they all work for me. I'm very confused. If even the preset fish alt bindings don't work for you, then I doubt the issue is with fzf.fish. I'm afraid I'm stumped and am out of ideas. Perhaps try asking in the fish-shell repo? |
Beta Was this translation helpful? Give feedback.
-
Are you able to write alternative characters by pressing ⌥l, ⌥v, and ⌥s in other apps though? |
Beta Was this translation helpful? Give feedback.
-
Indeed, I opened up Slack and typed them in: and got √߬ |
Beta Was this translation helpful? Give feedback.
-
For some reason, I am having the same problem in the terminal emulator in VSCode. the git bindings don't work but everything else does. EDIT: found solution here microsoft/vscode#11314 |
Beta Was this translation helpful? Give feedback.
-
@franciscolourenco did you try https://stackoverflow.com/questions/196357/making-iterm-to-translate-meta-key-in-the-same-way-as-in-other-oses? |
Beta Was this translation helpful? Give feedback.
-
@PatrickF1 Just tried, and remapping Option to Esc+ does work. Thanks! |
Beta Was this translation helpful? Give feedback.
-
Great to hear! I'm going to add this to the troubleshooting. |
Beta Was this translation helpful? Give feedback.
@franciscolourenco did you try https://stackoverflow.com/questions/196357/making-iterm-to-translate-meta-key-in-the-same-way-as-in-other-oses?