1fzf(1)                 fzf - a command-line fuzzy finder                fzf(1)
2
3
4

NAME

6       fzf - a command-line fuzzy finder
7
8

SYNOPSIS

10       fzf [options]
11
12

DESCRIPTION

14       fzf is a general-purpose command-line fuzzy finder.
15
16

OPTIONS

18   Search mode
19       -x, --extended
20              Extended-search  mode. Since 0.10.9, this is enabled by default.
21              You can disable it with +x or --no-extended.
22
23       -e, --exact
24              Enable exact-match
25
26       -i     Case-insensitive match (default: smart-case match)
27
28       +i     Case-sensitive match
29
30       --literal
31              Do not normalize latin script letters for matching.
32
33       --scheme=SCHEME
34              Choose scoring scheme tailored for different types of input.
35
36              default  Generic scoring scheme designed to work well  with  any
37              type of input
38              path      Scoring  scheme for paths (additional bonus point only
39              after path separator)
40              history  Scoring scheme for command history (no additional bonus
41              points).
42                       Sets --tiebreak=index as well.
43
44       --algo=TYPE
45              Fuzzy matching algorithm (default: v2)
46
47              v2     Optimal scoring algorithm (quality)
48              v1      Faster  but  not  guaranteed  to find the optimal result
49              (performance)
50
51
52       -n, --nth=N[,..]
53              Comma-separated list of field  index  expressions  for  limiting
54              search scope.  See FIELD INDEX EXPRESSION for the details.
55
56       --with-nth=N[,..]
57              Transform  the  presentation  of each line using field index ex‐
58              pressions
59
60       -d, --delimiter=STR
61              Field delimiter regex for --nth and  --with-nth  (default:  AWK-
62              style)
63
64       --disabled
65              Do  not  perform  search. With this option, fzf becomes a simple
66              selector interface rather than a "fuzzy finder". You  can  later
67              enable the search using enable-search or toggle-search action.
68
69   Search result
70       +s, --no-sort
71              Do not sort the result
72
73       --tac  Reverse the order of the input
74
75              e.g.
76                   history | fzf --tac --no-sort
77
78       --tiebreak=CRI[,..]
79              Comma-separated  list  of sort criteria to apply when the scores
80              are tied.
81
82              length  Prefers line with shorter length
83              chunk   Prefers line with shorter matched  chunk  (delimited  by
84              whitespaces)
85              begin   Prefers line with matched substring closer to the begin‐
86              ning
87              end     Prefers line with matched substring closer to the end
88              index   Prefers line that appeared earlier in the input stream
89
90              - Each criterion should appear only once in the list
91              - index is only allowed at the end of the list
92              - index is implicitly appended to the list when not specified
93              - Default is length (or equivalently length,index)
94              - If end is found in the list, fzf will scan each line backwards
95
96   Interface
97       -m, --multi
98              Enable multi-select with tab/shift-tab. It optionally  takes  an
99              integer  argument which denotes the maximum number of items that
100              can be selected.
101
102       +m, --no-multi
103              Disable multi-select
104
105       --no-mouse
106              Disable mouse
107
108       --bind=KEYBINDS
109              Comma-separated list of custom key bindings. See KEY/EVENT BIND‐
110              INGS for the details.
111
112       --cycle
113              Enable cyclic scroll
114
115       --keep-right
116              Keep  the  right end of the line visible when it's too long. Ef‐
117              fective only when the query string is empty.
118
119       --scroll-off=LINES
120              Number of screen lines to keep above or below when scrolling  to
121              the top or to the bottom (default: 0).
122
123       --no-hscroll
124              Disable horizontal scroll
125
126       --hscroll-off=COLS
127              Number of screen columns to keep to the right of the highlighted
128              substring (default: 10). Setting it to a large value will  cause
129              the text to be positioned on the center of the screen.
130
131       --filepath-word
132              Make  word-wise  movements  and actions respect path separators.
133              The following actions are affected:
134
135              backward-kill-word
136              backward-word
137              forward-word
138              kill-word
139
140       --jump-labels=CHARS
141              Label characters for jump and jump-accept
142
143   Layout
144       --height=[~]HEIGHT[%]
145              Display fzf window below the cursor with the  given  height  in‐
146              stead  of  using the full screen. When prefixed with ~, fzf will
147              automatically determine the height in the range according to the
148              input  size.  Note  that  adaptive height is not compatible with
149              top/bottom margin and padding given in percent size.
150
151       --min-height=HEIGHT
152              Minimum height when --height is given in percent (default:  10).
153              Ignored when --height is not specified.
154
155       --layout=LAYOUT
156              Choose the layout (default: default)
157
158              default       Display from the bottom of the screen
159              reverse       Display from the top of the screen
160              reverse-list   Display from the top of the screen, prompt at the
161              bottom
162
163
164       --reverse
165              A synonym for --layout=reverse
166
167
168       --border[=BORDER_OPT]
169              Draw border around the finder
170
171              rounded       Border with rounded corners (default)
172              sharp         Border with sharp corners
173              bold          Border with bold lines
174              double        Border with double lines
175              horizontal    Horizontal lines above and below the finder
176              vertical      Vertical lines on each side of the finder
177              top (up)
178              bottom (down)
179              left
180              right
181              none
182
183
184       --border-label[=LABEL]
185              Label to print on the horizontal border  line.  Should  be  used
186              with one of the following --border options.
187
188              * rounded
189              * sharp
190              * bold
191              * double
192              * horizontal
193              * top (up)
194              * bottom (down)
195
196              e.g.
197                # ANSI color codes are supported
198                # (with https://github.com/busyloop/lolcat)
199                label=$(curl  -s  http://metaphorpsum.com/sentences/1 | lolcat
200              -f)
201
202                # Border label at the center
203                fzf   --height=10   --border   --border-label="╢   $label   ╟"
204              --color=label:italic:black
205
206                # Left-aligned (positive integer)
207                fzf --height=10 --border --border-label="╢ $label ╟" --border-
208              label-pos=3 --color=label:italic:black
209
210                # Right-aligned (negative integer) on the bottom  line  (:bot‐
211              tom)
212                fzf --height=10 --border --border-label="╢ $label ╟" --border-
213              label-pos=-3:bottom --color=label:italic:black
214
215
216       --border-label-pos[=N[:top|bottom]]
217              Position of the border label on the border line. Specify a posi‐
218              tive  integer  as  the  column position from the left. Specify a
219              negative integer to right-align the label. Label is  printed  on
220              the  top  border  line  by default, add :bottom to put it on the
221              border line on the bottom. The default value 0 (or center)  will
222              put the label at the center of the border line.
223
224
225       --no-unicode
226              Use  ASCII  characters  instead of Unicode drawing characters to
227              draw borders, the spinner and the horizontal separator.
228
229
230       --margin=MARGIN
231              Comma-separated expression for margins around the finder.
232
233              TRBL     Same margin for top, right, bottom, and left
234              TB,RL    Vertical, horizontal margin
235              T,RL,B   Top, horizontal, bottom margin
236              T,R,B,L  Top, right, bottom, left margin
237
238              Each part can be given in absolute number or in percentage rela‐
239              tive to the terminal size with % suffix.
240
241              e.g.
242                   fzf --margin 10%
243                   fzf --margin 1,5%
244
245       --padding=PADDING
246              Comma-separated  expression  for padding inside the border. Pad‐
247              ding is distinguishable from margin only when --border option is
248              used.
249
250              e.g.
251                   fzf --margin 5% --padding 5% --border --preview 'cat {}' \
252                       --color bg:#222222,preview-bg:#333333
253
254              TRBL     Same padding for top, right, bottom, and left
255              TB,RL    Vertical, horizontal padding
256              T,RL,B   Top, horizontal, bottom padding
257              T,R,B,L  Top, right, bottom, left padding
258
259
260       --info=STYLE
261              Determines the display style of finder info (match counters).
262
263              default       Display on the next line to the prompt
264              inline        Display on the same line
265              hidden        Do not display finder info
266
267
268       --no-info
269              A synonym for --info=hidden
270
271
272       --separator=STR
273              The given string will be repeated to form the horizontal separa‐
274              tor on the info line (default: '─' or '-' depending on --no-uni‐
275              code).
276
277              ANSI color codes are supported.
278
279
280       --no-separator
281              Do  not display horizontal separator on the info line. A synonym
282              for --separator=''
283
284
285       --prompt=STR
286              Input prompt (default: '> ')
287
288       --pointer=STR
289              Pointer to the current line (default: '>')
290
291       --marker=STR
292              Multi-select marker (default: '>')
293
294       --header=STR
295              The given string will be printed as the sticky header. The lines
296              are  displayed  in the given order from top to bottom regardless
297              of --layout option, and are not  affected  by  --with-nth.  ANSI
298              color codes are processed even when --ansi is not set.
299
300       --header-lines=N
301              The first N lines of the input are treated as the sticky header.
302              When --with-nth is set, the lines are transformed just like  the
303              other lines that follow.
304
305       --header-first
306              Print header before the prompt line
307
308       --ellipsis=STR
309              Ellipsis to show when line is truncated (default: '..')
310
311   Display
312       --ansi Enable processing of ANSI color codes
313
314       --tabstop=SPACES
315              Number of spaces for a tab character (default: 8)
316
317       --color=[BASE_SCHEME][,COLOR_NAME[:ANSI_COLOR][:ANSI_ATTRIBUTES]]...
318              Color  configuration.  The name of the base color scheme is fol‐
319              lowed by custom color mappings.
320
321              BASE SCHEME:
322                  (default: dark on 256-color terminal, otherwise 16)
323
324                  dark    Color scheme for dark 256-color terminal
325                  light   Color scheme for light 256-color terminal
326                  16      Color scheme for 16-color terminal
327                  bw      No colors (equivalent to --no-color)
328
329              COLOR NAMES:
330                  fg         Text
331                  bg         Background
332                  preview-fg Preview window text
333                  preview-bg Preview window background
334                  hl         Highlighted substrings
335                  fg+        Text (current line)
336                  bg+        Background (current line)
337                  gutter     Gutter on the left (defaults to bg+)
338                  hl+        Highlighted substrings (current line)
339                  query      Query string
340                  disabled   Query string when search is disabled
341                  info       Info line (match counters)
342                  separator  Horizontal separator on info  line  (match  coun‐
343              ters)
344                  border     Border around the window (--border and --preview)
345                  label      Border label (--border-label and --preview-label)
346                  prompt     Prompt
347                  pointer    Pointer to the current line
348                  marker     Multi-select marker
349                  spinner    Streaming input indicator
350                  header     Header
351
352              ANSI COLORS:
353                  -1         Default terminal foreground/background color
354                             (or the original color of the text)
355                  0 ~ 15     16 base colors
356                    black
357                    red
358                    green
359                    yellow
360                    blue
361                    magenta
362                    cyan
363                    white
364                    bright-black (gray | grey)
365                    bright-red
366                    bright-green
367                    bright-yellow
368                    bright-blue
369                    bright-magenta
370                    bright-cyan
371                    bright-white
372                  16 ~ 255   ANSI 256 colors
373                  #rrggbb    24-bit colors
374
375              ANSI ATTRIBUTES: (Only applies to foreground colors)
376                  regular     Clears previously set attributes; should precede
377              the other ones
378                  bold
379                  underline
380                  reverse
381                  dim
382                  italic
383                  strikethrough
384
385              EXAMPLES:
386
387                   # Seoul256 theme with 8-bit colors
388                   # (https://github.com/junegunn/seoul256.vim)
389                   fzf       --color='bg:237,bg+:236,info:143,border:240,spin‐
390              ner:108' \
391                       --color='hl:65,fg:252,header:65,fg+:252' \
392                       --color='pointer:161,marker:168,prompt:110,hl+:108'
393
394                   # Seoul256 theme with 24-bit colors
395                   fzf       --color='bg:#4B4B4B,bg+:#3F3F3F,info:#BDBB72,bor‐
396              der:#6B6B6B,spinner:#98BC99' \
397                       --color='hl:#719872,fg:#D9D9D9,header:#719872,fg+:#D9D9D9'
398              \
399                       --color='pointer:#E12672,marker:#E17899,prompt:#98BEDE,hl+:#98BC99'
400
401       --no-bold
402              Do not use bold text
403
404       --black
405              Use black background
406
407   History
408       --history=HISTORY_FILE
409              Load search history from the specified file and update the  file
410              on  completion.   When  enabled, CTRL-N and CTRL-P are automati‐
411              cally remapped to next-history and previous-history.
412
413       --history-size=N
414              Maximum number of entries in the history file  (default:  1000).
415              The file is automatically truncated when the number of the lines
416              exceeds the value.
417
418   Preview
419       --preview=COMMAND
420              Execute the given command for the current line and  display  the
421              result  on  the  preview window. {} in the command is the place‐
422              holder that is replaced to the single-quoted string of the  cur‐
423              rent  line.  To  transform the replacement string, specify field
424              index expressions between the braces (See FIELD INDEX EXPRESSION
425              for the details).
426
427              e.g.
428                   fzf --preview='head -$LINES {}'
429                   ls  -l  |  fzf  --preview="echo user={3} when={-4..-2}; cat
430              {-1}" --header-lines=1
431
432              fzf exports $FZF_PREVIEW_LINES and $FZF_PREVIEW_COLUMNS so  that
433              they  represent  the  exact size of the preview window. (It also
434              overrides $LINES and $COLUMNS with the same values but they  can
435              be  reset  by  the default shell, so prefer to refer to the ones
436              with FZF_PREVIEW_ prefix.)
437
438              A placeholder expression starting with + flag will  be  replaced
439              to  the  space-separated list of the selected lines (or the cur‐
440              rent line if no selection was made) individually quoted.
441
442              e.g.
443                   fzf --multi --preview='head -10 {+}'
444                   git log --oneline | fzf --multi --preview 'git show {+1}'
445
446              When using a field index expression, leading and trailing white‐
447              space  is  stripped from the replacement string. To preserve the
448              whitespace, use the s flag.
449
450              Also, {q} is replaced to the current query string,  and  {n}  is
451              replaced  to  zero-based  ordinal index of the line. Use {+n} if
452              you want all index numbers when multiple lines are selected.
453
454              A placeholder expression with f flag is replaced to the path  of
455              a  temporary  file that holds the evaluated list. This is useful
456              when you multi-select a large number of items and the length  of
457              the evaluated string may exceed ARG_MAX.
458
459              e.g.
460                   #  Press CTRL-A to select 100K items and see the sum of all
461              the numbers.
462                   # This won't work properly without 'f' flag due to  ARG_MAX
463              limit.
464                   seq 100000 | fzf --multi --bind ctrl-a:select-all \
465                                    --preview   "awk  '{sum+=\$1}  END  {print
466              sum}' {+f}"
467
468              Note that you can escape a placeholder pattern by  prepending  a
469              backslash.
470
471              Preview  window  will be updated even when there is no match for
472              the current query if any of the placeholder  expressions  evalu‐
473              ates to a non-empty string.
474
475              Since  0.24.0, fzf can render partial preview content before the
476              preview command completes. ANSI escape sequence for clearing the
477              display  (CSI  2 J) is supported, so you can use it to implement
478              preview window that is constantly updating.
479
480              e.g.
481                    fzf --preview 'for i in $(seq 100000); do
482                      (( i % 200 == 0 )) && printf "\033[2J"
483                      echo "$i"
484                      sleep 0.01
485                    done'
486
487
488       --preview-label[=LABEL]
489              Label to print on the horizontal border line of the preview win‐
490              dow.   Should be used with one of the following --preview-window
491              options.
492
493              * border-rounded (default)
494              * border-sharp
495              * border-bold
496              * border-double
497              * border-horizontal
498              * border-top
499              * border-bottom
500
501
502       --preview-label-pos[=N[:top|bottom]]
503              Position of the border label on the border line of  the  preview
504              window.  Specify  a positive integer as the column position from
505              the left. Specify a negative integer to right-align  the  label.
506              Label  is printed on the top border line by default, add :bottom
507              to put it on the border line on the bottom. The default value  0
508              (or center) will put the label at the center of the border line.
509
510
511       --preview-window=[POSITION][,SIZE[%]][,border-BOR‐
512       DER_OPT][,[no]wrap][,[no]follow][,[no]cycle][,[no]hidden][,+SCROLL[OFF‐
513       SETS][/DENOM]][,~HEADER_LINES][,default][,<SIZE_THRESHOLD(ALTERNA‐
514       TIVE_LAYOUT)]
515
516              POSITION: (default: right)
517                  up
518                  down
519                  left
520                  right
521
522              Determines the layout of the preview window.
523
524              * If the argument contains :hidden, the preview window  will  be
525              hidden by default until toggle-preview action is triggered.
526
527              * If size is given as 0, preview window will not be visible, but
528              fzf will still execute the command in the background.
529
530              * Long lines are truncated by default. Line wrap can be  enabled
531              with wrap flag.
532
533              *  Preview  window  will automatically scroll to the bottom when
534              follow flag is set, similarly to how tail -f works.
535
536                     e.g.
537                           fzf --preview-window follow  --preview  'for  i  in
538                     $(seq 100000); do
539                             echo "$i"
540                             sleep 0.01
541                             (( i % 300 == 0 )) && printf "\033[2J"
542                           done'
543
544              * Cyclic scrolling is enabled with cycle flag.
545
546              * To change the style of the border of the preview window, spec‐
547              ify one of the options for --border with border-  prefix.   e.g.
548              border-rounded  (border  with  rounded  edges, default), border-
549              sharp (border with sharp edges), border-left, border-none, etc.
550
551              * [:+SCROLL[OFFSETS][/DENOM]] determines the initial scroll off‐
552              set of the preview window.
553
554                - SCROLL can be either a numeric integer or a single-field in‐
555              dex expression that refers to a numeric integer.
556
557                - The optional OFFSETS part is for adjusting the base  offset.
558              It  should  be given as a series of signed integers (-INTEGER or
559              +INTEGER).
560
561                - The final /DENOM part is for specifying a  fraction  of  the
562              preview window height.
563
564              *  ~HEADER_LINES  keeps  the  top N lines as the fixed header so
565              that they are always visible.
566
567              * default resets all options previously set to the default.
568
569                     e.g.
570                          # Non-default scroll window positions and sizes
571                          fzf --preview="head {}" --preview-window=up,30%
572                          fzf --preview="file {}" --preview-window=down,1
573
574                          # Initial scroll offset is set to the line number of
575                     each line of
576                          # git grep output *minus* 5 lines (-5)
577                          git grep --line-number '' |
578                            fzf  --delimiter  :  --preview 'nl {1}' --preview-
579                     window '+{2}-5'
580
581                          # Preview with bat, matching line in the  middle  of
582                     the window below
583                          # the fixed header of the top 3 lines
584                          #
585                          #   ~3    Top 3 lines as the fixed header
586                          #   +{2}  Base scroll offset extracted from the sec‐
587                     ond field
588                          #   +3    Extra offset to compensate for the  3-line
589                     header
590                          #   /2    Put in the middle of the preview area
591                          #
592                          git grep --line-number '' |
593                            fzf --delimiter : \
594                                --preview   'bat  --style=full  --color=always
595                     --highlight-line {2} {1}' \
596                                --preview-window '~3,+{2}+3/2'
597
598                          # Display top 3 lines as the fixed header
599                          fzf --preview 'bat --style=full  --color=always  {}'
600                     --preview-window '~3'
601
602              *  You  can  specify an alternative set of options that are used
603              only when the size
604                of the preview window is below a certain threshold. Note  that
605              only one
606                alternative layout is allowed.
607
608                     e.g.
609                           fzf --preview 'cat {}' --preview-window 'right,bor‐
610                     der-left,<30(up,30%,border-bottom)'
611
612
613   Scripting
614       -q, --query=STR
615              Start the finder with the given query
616
617       -1, --select-1
618              If there is only one match for the initial query  (--query),  do
619              not  start  interactive finder and automatically select the only
620              match
621
622       -0, --exit-0
623              If there is no match for the initial  query  (--query),  do  not
624              start interactive finder and exit immediately
625
626       -f, --filter=STR
627              Filter  mode.  Do  not  start interactive finder. When used with
628              --no-sort, fzf becomes a fuzzy-version of grep.
629
630       --print-query
631              Print query as the first line
632
633       --expect=KEY[,..]
634              Comma-separated list of keys that can be used to complete fzf in
635              addition  to the default enter key. When this option is set, fzf
636              will print the name of the key pressed as the first line of  its
637              output  (or  as  the second line if --print-query is also used).
638              The line will be empty if fzf is completed with the default  en‐
639              ter  key.  If  --expect  option is specified multiple times, fzf
640              will expect the union of the keys. --no-expect  will  clear  the
641              list.
642
643              e.g.
644                   fzf --expect=ctrl-v,ctrl-t,alt-s --expect=f1,f2,~,@
645
646       --read0
647              Read  input delimited by ASCII NUL characters instead of newline
648              characters
649
650       --print0
651              Print output delimited by ASCII NUL characters instead  of  new‐
652              line characters
653
654       --sync Synchronous search for multi-staged filtering. If specified, fzf
655              will launch ncurses finder only after the input stream  is  com‐
656              plete.
657
658              e.g. fzf --multi | fzf --sync
659
660       --version
661              Display version information and exit
662
663
664       Note that most options have the opposite versions with --no- prefix.
665
666

ENVIRONMENT VARIABLES

668       FZF_DEFAULT_COMMAND
669              Default  command  to use when input is tty. On *nix systems, fzf
670              runs the command with $SHELL -c if SHELL is set, otherwise  with
671              sh  -c, so in this case make sure that the command is POSIX-com‐
672              pliant.
673
674       FZF_DEFAULT_OPTS
675              Default options. e.g. export FZF_DEFAULT_OPTS="--extended  --cy‐
676              cle"
677
678

EXIT STATUS

680       0      Normal exit
681       1      No match
682       2      Error
683       130    Interrupted with CTRL-C or ESC
684
685

FIELD INDEX EXPRESSION

687       A  field  index expression can be a non-zero integer or a range expres‐
688       sion ([BEGIN]..[END]). --nth and --with-nth take a comma-separated list
689       of field index expressions.
690
691
692   Examples
693       1      The 1st field
694       2      The 2nd field
695       -1     The last field
696       -2     The 2nd to last field
697       3..5   From the 3rd field to the 5th field
698       2..    From the 2nd field to the last field
699       ..-3   From the 1st field to the 3rd to the last field
700       ..     All the fields
701
702

EXTENDED SEARCH MODE

704       Unless  specified  otherwise, fzf will start in "extended-search mode".
705       In this mode, you can specify multiple patterns  delimited  by  spaces,
706       such as: 'wild ^music .mp3$ sbtrkt !rmx
707
708       You  can  prepend  a backslash to a space (\ ) to match a literal space
709       character.
710
711
712   Exact-match (quoted)
713       A term that is prefixed by a single-quote character (') is  interpreted
714       as  an "exact-match" (or "non-fuzzy") term. fzf will search for the ex‐
715       act occurrences of the string.
716
717
718   Anchored-match
719       A term can be prefixed by ^, or suffixed by $ to  become  an  anchored-
720       match  term.  Then fzf will search for the lines that start with or end
721       with the given string. An anchored-match term is  also  an  exact-match
722       term.
723
724
725   Negation
726       If a term is prefixed by !, fzf will exclude the lines that satisfy the
727       term from the result. In this case, fzf performs  exact  match  by  de‐
728       fault.
729
730
731   Exact-match by default
732       If  you don't prefer fuzzy matching and do not wish to "quote" (prefix‐
733       ing with ') every word, start fzf with -e or --exact option. Note  that
734       when --exact is set, '-prefix "unquotes" the term.
735
736
737   OR operator
738       A  single  bar  character term acts as an OR operator. For example, the
739       following query matches entries that start with core and end  with  ei‐
740       ther go, rb, or py.
741
742       e.g. ^core go$ | rb$ | py$
743
744

KEY/EVENT BINDINGS

746       --bind  option  allows you to bind a key or an event to one or more ac‐
747       tions. You can use it to customize key bindings  or  implement  dynamic
748       behaviors.
749
750       --bind  takes a comma-separated list of binding expressions. Each bind‐
751       ing expression is KEY:ACTION or EVENT:ACTION.
752
753       e.g.
754            fzf --bind=ctrl-j:accept,ctrl-k:kill-line
755
756
757   AVAILABLE KEYS: (SYNONYMS)
758       ctrl-[a-z]
759       ctrl-space
760       ctrl-\
761       ctrl-]
762       ctrl-^      (ctrl-6)
763       ctrl-/      (ctrl-_)
764       ctrl-alt-[a-z]
765       alt-[*]     (Any case-sensitive single character is allowed)
766       f[1-12]
767       enter       (return ctrl-m)
768       space
769       bspace      (bs)
770       alt-up
771       alt-down
772       alt-left
773       alt-right
774       alt-enter
775       alt-space
776       alt-bspace  (alt-bs)
777       tab
778       btab        (shift-tab)
779       esc
780       del
781       up
782       down
783       left
784       right
785       home
786       end
787       insert
788       pgup        (page-up)
789       pgdn        (page-down)
790       shift-up
791       shift-down
792       shift-left
793       shift-right
794       alt-shift-up
795       alt-shift-down
796       alt-shift-left
797       alt-shift-right
798       left-click
799       right-click
800       double-click
801       or any single character
802
803
804   AVAILABLE EVENTS:
805       start
806              Triggered only once when fzf finder starts. Since  fzf  consumes
807              the input stream asynchronously, the input list is not available
808              unless you use --sync.
809
810              e.g.
811                   # Move cursor to the last item and select all items
812                   seq 1000 | fzf --multi --sync --bind start:last+select-all
813       change
814              Triggered whenever the query string is changed
815
816              e.g.
817                   # Move cursor to the first  entry  whenever  the  query  is
818              changed
819                   fzf --bind change:first
820
821       backward-eof
822              Triggered  when the query string is already empty and you try to
823              delete it backward.
824
825              e.g.
826                   fzf --bind backward-eof:abort
827
828
829   AVAILABLE ACTIONS:
830       A key or an event can be bound to one or more of the following actions.
831
832         ACTION:                   DEFAULT BINDINGS (NOTES):
833           abort                      ctrl-c  ctrl-g  ctrl-q  esc
834           accept                     enter   double-click
835           accept-non-empty           (same as accept except that it  prevents
836       fzf from exiting without selection)
837           backward-char              ctrl-b  left
838           backward-delete-char       ctrl-h  bspace
839           backward-delete-char/eof    (same  as  backward-delete-char  except
840       aborts fzf if query is empty)
841           backward-kill-word         alt-bs
842           backward-word              alt-b   shift-left
843           beginning-of-line          ctrl-a  home
844           cancel                     (clear query string if not empty,  abort
845       fzf otherwise)
846           change-preview(...)        (change --preview option)
847           change-preview-window(...)  (change --preview-window option; rotate
848       through the multiple option sets separated by '|')
849           change-prompt(...)         (change prompt to the given string)
850           clear-screen               ctrl-l
851           clear-selection            (clear multi-selection)
852           close                      (close preview window if open, abort fzf
853       otherwise)
854           clear-query                (clear query string)
855           delete-char                del
856           delete-char/eof              ctrl-d  (same  as  delete-char  except
857       aborts fzf if query is empty)
858           deselect
859           deselect-all               (deselect all matches)
860           disable-search             (disable search functionality)
861           down                       ctrl-j  ctrl-n  down
862           enable-search              (enable search functionality)
863           end-of-line                ctrl-e  end
864           execute(...)               (see below for the details)
865           execute-silent(...)        (see below for the details)
866           first                      (move to the first match)
867           forward-char               ctrl-f  right
868           forward-word               alt-f   shift-right
869           ignore
870           jump                       (EasyMotion-like 2-keystroke movement)
871           jump-accept                (jump and accept)
872           kill-line
873           kill-word                  alt-d
874           last                       (move to the last match)
875           next-history               (ctrl-n on --history)
876           page-down                  pgdn
877           page-up                    pgup
878           half-page-down
879           half-page-up
880           preview(...)               (see below for the details)
881           preview-down               shift-down
882           preview-up                 shift-up
883           preview-page-down
884           preview-page-up
885           preview-half-page-down
886           preview-half-page-up
887           preview-bottom
888           preview-top
889           previous-history           (ctrl-p on --history)
890           print-query                (print query and exit)
891           put                        (put the character to the prompt)
892           refresh-preview
893           rebind(...)                (rebind bindings after unbind)
894           reload(...)                (see below for the details)
895           replace-query              (replace query string with  the  current
896       selection)
897           select
898           select-all                 (select all matches)
899           toggle                     (right-click)
900           toggle-all                 (toggle all matches)
901           toggle+down                ctrl-i  (tab)
902           toggle-in                   (--layout=reverse*  ?  toggle+up : tog‐
903       gle+down)
904           toggle-out                 (--layout=reverse* ? toggle+down :  tog‐
905       gle+up)
906           toggle-preview
907           toggle-preview-wrap
908           toggle-search              (toggle search functionality)
909           toggle-sort
910           toggle+up                  btab    (shift-tab)
911           unbind(...)                (unbind bindings)
912           unix-line-discard          ctrl-u
913           unix-word-rubout           ctrl-w
914           up                         ctrl-k  ctrl-p  up
915           yank                       ctrl-y
916
917
918   ACTION COMPOSITION
919       Multiple actions can be chained using + separator.
920
921       e.g.
922            fzf --multi --bind 'ctrl-a:select-all+accept'
923            fzf --multi --bind 'ctrl-a:select-all' --bind 'ctrl-a:+accept'
924
925
926   ACTION ARGUMENT
927       An action denoted with (...) suffix takes an argument.
928
929       e.g.
930            fzf --bind 'ctrl-a:change-prompt(NewPrompt> )'
931            fzf --bind 'ctrl-v:preview(cat {})' --preview-window hidden
932
933       If the argument contains parentheses, fzf may fail to parse the expres‐
934       sion. In that case, you can use any of the following alternative  nota‐
935       tions to avoid parse errors.
936
937           action-name[...]
938           action-name~...~
939           action-name!...!
940           action-name@...@
941           action-name#...#
942           action-name$...$
943           action-name%...%
944           action-name^...^
945           action-name&...&
946           action-name*...*
947           action-name;...;
948           action-name/.../
949           action-name|...|
950           action-name:...
951              The  last  one is the special form that frees you from parse er‐
952              rors as it does not expect the closing character. The  catch  is
953              that  it  should  be the last one in the comma-separated list of
954              key-action pairs.
955
956
957   COMMAND EXECUTION
958       With execute(...) action, you can execute  arbitrary  commands  without
959       leaving  fzf.  For example, you can turn fzf into a simple file browser
960       by binding enter key to less command like follows.
961
962           fzf --bind "enter:execute(less {})"
963
964       You can use the same placeholder expressions as in --preview.
965
966       fzf switches to the alternate screen when executing a command. However,
967       if  the command is expected to complete quickly, and you are not inter‐
968       ested in its output, you might  want  to  use  execute-silent  instead,
969       which  silently  executes  the command without the switching. Note that
970       fzf will not be responsive until the command is complete. For asynchro‐
971       nous  execution,  start  your command as a background process (i.e. ap‐
972       pending &).
973
974       On *nix systems, fzf runs the command with $SHELL -c if SHELL  is  set,
975       otherwise  with  sh  -c,  so in this case make sure that the command is
976       POSIX-compliant.
977
978
979   RELOAD INPUT
980       reload(...) action is used to dynamically update the input list without
981       restarting fzf. It takes the same command template with placeholder ex‐
982       pressions as execute(...).
983
984       See https://github.com/junegunn/fzf/issues/1750 for more info.
985
986       e.g.
987            # Update the list of processes by pressing CTRL-R
988            ps -ef | fzf --bind 'ctrl-r:reload(ps -ef)' --header 'Press CTRL-R
989       to reload' \
990                         --header-lines=1 --layout=reverse
991
992            # Integration with ripgrep
993            RG_PREFIX="rg  --column  --line-number --no-heading --color=always
994       --smart-case "
995            INITIAL_QUERY="foobar"
996            FZF_DEFAULT_COMMAND="$RG_PREFIX '$INITIAL_QUERY'" \
997              fzf --bind "change:reload:$RG_PREFIX {q} || true" \
998                  --ansi --disabled --query "$INITIAL_QUERY"
999
1000
1001   PREVIEW BINDING
1002       With preview(...) action, you can specify  multiple  different  preview
1003       commands  in addition to the default preview command given by --preview
1004       option.
1005
1006       e.g.
1007            # Default preview command with an extra preview binding
1008            fzf --preview 'file {}' --bind '?:preview:cat {}'
1009
1010            # A preview binding with no default preview command
1011            # (Preview window is initially empty)
1012            fzf --bind '?:preview:cat {}'
1013
1014            # Preview window hidden by default, it appears when you first  hit
1015       '?'
1016            fzf --bind '?:preview:cat {}' --preview-window hidden
1017
1018
1019   CHANGE PREVIEW WINDOW ATTRIBUTES
1020       change-preview-window  action  can  be used to change the properties of
1021       the preview window. Unlike the --preview-window option, you can specify
1022       multiple sets of options separated by '|' characters.
1023
1024       e.g.
1025            # Rotate through the options using CTRL-/
1026            fzf   --preview   'cat   {}'   --bind  'ctrl-/:change-preview-win‐
1027       dow(right,70%|down,40%,border-horizontal|hidden|right)'
1028
1029            # The default properties given by  `--preview-window`  are  inher‐
1030       ited, so an empty string in the list is interpreted as the default
1031            fzf  --preview  'cat  {}' --preview-window 'right,40%,border-left'
1032       --bind 'ctrl-/:change-preview-window(70%|down,border-top|hidden|)'
1033
1034            # This is equivalent to toggle-preview action
1035            fzf --preview 'cat {}'  --bind  'ctrl-/:change-preview-window(hid‐
1036       den|)'
1037
1038

AUTHOR

1040       Junegunn Choi (junegunn.c@gmail.com)
1041
1042

SEE ALSO

1044       Project homepage:
1045              https://github.com/junegunn/fzf
1046
1047       Extra Vim plugin:
1048              https://github.com/junegunn/fzf.vim
1049
1050

LICENSE

1052       MIT
1053
1054
1055
1056fzf 0.35.1                         Nov 2022                             fzf(1)
Impressum