Closed schabrolles closed 2 months ago
My understanding is we can only "unbind" or "rebind" an action that has been already defined from the start.
Correct.
I would like to start with this "auto-refresh" disabled by default.
You can unbind
the load
on start
like so:
date |
fzf --prompt 'hold> ' \
--bind 'start:unbind(load)' \
--bind 'load:reload-sync:sleep 1; date' \
--bind 'space:transform:
[[ $FZF_PROMPT =~ watch ]] &&
echo "change-prompt(hold> )+unbind(load)" ||
echo "change-prompt(watch> )+rebind(load)+reload-sync(date)"
'
Many thanks 🙏 fzf is a really cool, flexible. great work.
Checklist
man fzf
)Output of
fzf --version
0.51.0
OS
Shell
Problem / Steps to reproduce
I'm looking for a way to toggle an auto-refresh (watch mode) of the main view when I press
ctrl-w
.For the moment, I can achieve this but the watch mode must be activate with a --bind option and I can only deactivate/reactivate it by pressing
ctrl-w
. I would like to start with this "auto-refresh" disabled by default.My understanding is we can only "unbind" or "rebind" an action that has been already defined from the start.
snip from what I use (FZF_DEFAULT_COMMAND is a kind of "kubectl get pod")
I don't know if it is possible to have an option to create new
bind
withtransform
.