Fzf: Difference between revisions
From wikinotes
No edit summary |
|||
Line 37: | Line 37: | ||
<blockquote> | <blockquote> | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
result=$(find . | fzf +m) # choose single | result=$(find . | fzf +m) # choose single | ||
results=($(find . | fzf -m)) # choose single or multiple | results=($(find . | fzf -m)) # choose single or multiple | ||
</syntaxhighlight> | </syntaxhighlight> | ||
</blockquote><!-- CLI Usage --> | </blockquote><!-- CLI Usage --> | ||
</blockquote><!-- Usage --> | </blockquote><!-- Usage --> | ||
= Extensions = | |||
<blockquote> | |||
{| class="wikitable" | |||
|- | |||
| fzf-tab (fzf-on-tabcomplete) || https://github.com/Aloxaf/fzf-tab | |||
|- | |||
|} | |||
</blockquote><!-- Extensions --> |
Revision as of 18:25, 18 September 2021
fzf is a tool that lets you fuzzy search lines piped to it on stdin.
Documentation
github https://github.com/junegunn/fzf man fzf
https://man.archlinux.org/man/community/fzf/fzf.1.en
Usage
Keybindings
Default Keybindings
up/down # go up/down entry tab # mark entry as selected (when multi-select active) enter # single-select and exit # type # search resultsYou can set your own keybindings as well
See AVAILABLE ACTIONS in man fzfexport FZF_DEFAULT_OPTS='\ --bind \ ctrl-a:select-all,\ ctrl-d:deselect-all'CLI Usage
result=$(find . | fzf +m) # choose single results=($(find . | fzf -m)) # choose single or multiple
Extensions
fzf-tab (fzf-on-tabcomplete) https://github.com/Aloxaf/fzf-tab