2 ms·
The crazy thing about this is how simple the code is. _sysz_list_units | fzf \ --exact \ --multi \ --ansi \ --reverse
by Spivak 5y ago
The crazy thing about this is how simple the code is.
_sysz_list_units |
fzf \
--exact \
--multi \
--ansi \
--reverse \
--no-sort \
--history="$SYSZ_HISTORY" \
--prompt="Units: " \
--bind "ctrl-v:preview('${BASH_SOURCE[0]}' _fzf_cat {})" \
--preview="'${BASH_SOURCE[0]}' _fzf_preview {}" \
--preview-window=70% |
readarray -t PICKS
This is the whole UI. Just give it a list of things to search through, a prompt, and a command for previewing the thing and fzf handles literally all the rest of the UI for you.