Conversation
lingrlongr
commented
Nov 15, 2022
- Added support for different keycodes for up/down
- Added support for quitting the menu
- Added support for different keycodes for up/down - Added support for quitting the menu
|
|
||
|
|
||
| GITBASH_KEY_UP = 450 | ||
| GITBASH_KEY_DOWN = 456 |
There was a problem hiding this comment.
It's an Windows application that provides an emulation layer for a Git command line experience in a familiar bash interface.
There was a problem hiding this comment.
I think instead of hard-code these special codes here, it would be better to have a method for users to config them
There was a problem hiding this comment.
I was about to fork pick to have the ability to exit!
This would combine nicely with the ability to set custom keys (so pick doesn't have to have custom keys for gitbash, or VS code as I saw in another issue).
I could work on this if the author of this PR is not interested to work on it anymore
There was a problem hiding this comment.
after thinking a bit about it (and this may be already clear for the maintainers), custom key bindings are already supported by the ability to set them at the module level. For instance to support the numpad to navigate, one might simply do
import pick
pick.KEYS_UP += (ord("8"),)
pick.KEYS_DOWN += (ord("2"),)
KEY_NUMPAD_ENTER = 459
pick.KEYS_ENTER += (KEY_NUMPAD_ENTER,)Because of this, I will only tackle the exit option, to reduce the scope of my PR