Add a Go-based command_palette kitten that provides a searchable,
interactive overlay for browsing and triggering keyboard shortcuts
and actions.
- New Go kitten at kittens/command_palette/ with FZF fuzzy search,
grouped/flat views, and remote control action triggering
- Python collect_keys_data() does data collection, passed via stdin
- Navigation: arrows, ctrl+j/k (vim), ctrl+n/p (emacs), page up/down
- Enter triggers the selected action via RC command
- Help text displayed in footer for selected binding
- Added Go tests (main_test.go) and Python tests (command_palette.py)
If the user's bash profile contains 'set -u' / 'set -o nounset'
(to protect against typos in variable names; think "rm -Rf $TMp/*"),
starting a new kitty terminal resulted in a
bash: sourced: unbound variable
message. Also, the error disabled kitty's shell integration.
This PR fixes/supersedes bba4ce22, which was based on an incorrect
assumption.
If the user's bash profile contains 'set -u' (to protect against typos
in variable names; think "rm -Rf $TMp/*"), starting a new kitty terminal
resulted in a spurious `bash: sourced: unbound variable` message.
Remove usage of the `-P` option from the print inside the
`_ksi_precmd` and `_ksi_preexec` functions. Instead, the result of
`builtin print -Pn "%m"` is stored in the local variable `hostname`.
This mitigates accidental expansion of variables in the command to be
executed.
Fixes#8193.
On some Macs (e.g. M1, 2020), `uname` returns 'Darwin' and `uname -m`
retuns 'arm64', this case is not handled in shell-integration. As a
result, ssh kitten transfer fails with:
>> Unknown CPU architecture arm64
Fix this by adding the case for arch=arm64 in kitten and kitty
shell-integration scripts.
Tested this on Mac Pro (M1, 2020).
The upcoming fish 3.8 release will output OSC 133 sequences
unconditionally [1].
I tested ctrl-shift-{g,x,z} bindings both without and with kitty's
shell integration on top; everything seems to work.
Let's simplify kitty integration by removing the markers for the
upcoming fish >= 3.8.
I have hopes that the native OSC 133 implementation address #7200
though I'm not sure if I could reproduce this bug (I only saw a
similar bug when `fish_handle_reflow` was not enabled, which fish
also does now (same commit)).
cc @iacore let me know if you can reproduce #7200 with latest fish master.
[1]: 3b9e3e251b