charmbracelet / gum

A tool for glamorous shell scripts 🎀
MIT License
18.37k stars 348 forks source link

[Feature] Filter allow moving selection up/down with vim keys (i.e. ctrl+j / ctrl+k) #52

Closed ndom91 closed 2 years ago

ndom91 commented 2 years ago

Thanks for this great little bash helper library!

I have a few shell scripts that use fzf to implement a gum filter type of functionality. However, after filtering down to a selection of say 3-4 results, I often then navigate to the one I want with ctrl + vim keys (i.e. ctrl+j (down) or ctrl+k (up)). This seems to be an fzf-only thing.

Gum currenlty only supports using the arrow keys to navigate up/down between items in the filter dialog.

I would love to be able to use ctrl+k / ctrl+j to navigate up/down in the list as well!

kencx commented 2 years ago

Good news, this has already been added in 610e054fb51b5a3d83c554fc7583bd768f048580!

maaslalani commented 2 years ago

Thank you so much for creating this issue @ndom91

Like @kencx mentioned this has been added in recently because it is a really great idea! It should be available in the next release or you can install from HEAD to get the latest changes.

ndom91 commented 2 years ago

Thank you so much for creating this issue @ndom91

Like @kencx mentioned this has been added in recently because it is a really great idea! It should be available in the next release or you can install from HEAD to get the latest changes.

Wow this is the fastest any feature request of mine has ever been turned around 😂

Keep up the great work!