summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoe Hillenbrand <joehillen@gmail.com>2021-09-20 23:12:08 -0700
committerJoe Hillenbrand <joehillen@gmail.com>2021-09-20 23:12:08 -0700
commit37d0d2c3495f803bc0c0b7f0f501495513cad189 (patch)
tree6a7dd484d48a89faa26eba4d7fd303f6a43995bc
parent0372bcf96c25ac5d66dec93118acac9f7093ef23 (diff)
press '?' to show keybindings
-rwxr-xr-xsysz3
1 files changed, 3 insertions, 0 deletions
diff --git a/sysz b/sysz
index 9776c46..9aa25f4 100755
--- a/sysz
+++ b/sysz
@@ -16,6 +16,7 @@ Keybindings:
ctrl-r Run daemon-reload.
ctrl-p History previous.
ctrl-n History next.
+ ? Show keybindings.
EOF
}
@@ -380,6 +381,8 @@ while :; do
--no-sort \
--history="$SYSZ_HISTORY" \
--prompt="Units: " \
+ --header '? for keybindings' \
+ --bind "?:preview(echo '$(_sysz_keys)')" \
--bind "ctrl-r:clear-selection+clear-query+change-prompt(Reload: )+close+reload('${BASH_SOURCE[0]}' _fzf_daemon_reload)+first" \
--bind "ctrl-v:preview('${BASH_SOURCE[0]}' _fzf_cat {})" \
--bind "ctrl-s:clear-selection+clear-query+change-prompt(States: )+close+reload('${BASH_SOURCE[0]}' _fzf_states)+first" \