-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
feat: allow override of plugins & hotkeys shortcuts #2510
Conversation
awesome dude ! |
@derailed can you check this out ? 🙏 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@othmane399 Clever! Thanks for this update Othmane.
We should doc this out so user are aware of this functionality.
Also tho this might open pandora's box and hose familiar keys it does enable folks to override keys to their liking.
@@ -76,7 +76,7 @@ func hotKeyActions(r Runner, aa ui.KeyActions) error { | |||
continue | |||
} | |||
_, ok := aa[key] | |||
if ok { | |||
if ok && !hk.Override { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should flag this in the logs so users can check why a familiar key either stopped working or enabled a different functionality... Best to let users know which plugin/hotkey caused it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @derailed, done for docs and logging :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@othmane399 Thank you for the updates!
@@ -524,8 +524,9 @@ In order to surface hotkeys globally please follow these steps: | |||
description: Xray Deployments | |||
command: xray deploy | |||
# Hitting Ctrl-U view the resources in the namespace of your current selection | |||
ctrl-u: | |||
shortCut: Ctrl-U | |||
shift-s: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are we changing the shortcut? No longer matches the comment above?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello, I've fixed the command above, the idea here was to choose a shortcut that already exist to makes the override logic in the example (as Shift-S default shortcut sort pods)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@othmane399 Thank you for the updates Othmane!
* feat: allow override of plugins & hotkeys shortcuts * add docs and log.info when overrides * edit log message * fix doc * Update README.md
This PR make the possibility to override some default keys by a plugin shortcut or a hotkey.
It resolve this issue #1736
adding
override: true
in a plugin or hotkey definition makes the override possible.