doing 2.0.19 → 2.0.23
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +15 -0
- data/Gemfile.lock +15 -5
- data/README.md +1 -1
- data/bin/doing +2 -18
- data/doing.gemspec +5 -4
- data/doing.rdoc +2 -2
- data/generate_completions.sh +3 -3
- data/lib/doing/cli_status.rb +6 -2
- data/lib/doing/completion/bash_completion.rb +185 -0
- data/lib/doing/completion/fish_completion.rb +175 -0
- data/lib/doing/completion/string.rb +17 -0
- data/lib/doing/completion/zsh_completion.rb +140 -0
- data/lib/doing/completion.rb +39 -0
- data/lib/doing/version.rb +1 -1
- data/lib/doing/wwid.rb +19 -5
- data/lib/doing.rb +1 -1
- data/lib/helpers/fzf/.goreleaser.yml +119 -0
- data/lib/helpers/fzf/.rubocop.yml +28 -0
- data/lib/helpers/fzf/ADVANCED.md +565 -0
- data/lib/helpers/fzf/BUILD.md +49 -0
- data/lib/helpers/fzf/CHANGELOG.md +1193 -0
- data/lib/helpers/fzf/Dockerfile +11 -0
- data/lib/helpers/fzf/LICENSE +21 -0
- data/lib/helpers/fzf/Makefile +166 -0
- data/lib/helpers/fzf/README-VIM.md +486 -0
- data/lib/helpers/fzf/README.md +712 -0
- data/lib/helpers/fzf/bin/fzf-tmux +233 -0
- data/lib/helpers/fzf/doc/fzf.txt +512 -0
- data/lib/helpers/fzf/go.mod +17 -0
- data/lib/helpers/fzf/go.sum +31 -0
- data/lib/helpers/fzf/install +382 -0
- data/lib/helpers/fzf/install.ps1 +65 -0
- data/lib/helpers/fzf/main.go +14 -0
- data/lib/helpers/fzf/man/man1/fzf-tmux.1 +68 -0
- data/lib/helpers/fzf/man/man1/fzf.1 +1001 -0
- data/lib/helpers/fzf/plugin/fzf.vim +1048 -0
- data/lib/helpers/fzf/shell/completion.bash +381 -0
- data/lib/helpers/fzf/shell/completion.zsh +329 -0
- data/lib/helpers/fzf/shell/key-bindings.bash +96 -0
- data/lib/helpers/fzf/shell/key-bindings.fish +172 -0
- data/lib/helpers/fzf/shell/key-bindings.zsh +114 -0
- data/lib/helpers/fzf/src/LICENSE +21 -0
- data/lib/helpers/fzf/src/algo/algo.go +884 -0
- data/lib/helpers/fzf/src/algo/algo_test.go +197 -0
- data/lib/helpers/fzf/src/algo/normalize.go +492 -0
- data/lib/helpers/fzf/src/ansi.go +409 -0
- data/lib/helpers/fzf/src/ansi_test.go +427 -0
- data/lib/helpers/fzf/src/cache.go +81 -0
- data/lib/helpers/fzf/src/cache_test.go +39 -0
- data/lib/helpers/fzf/src/chunklist.go +89 -0
- data/lib/helpers/fzf/src/chunklist_test.go +80 -0
- data/lib/helpers/fzf/src/constants.go +85 -0
- data/lib/helpers/fzf/src/core.go +351 -0
- data/lib/helpers/fzf/src/history.go +96 -0
- data/lib/helpers/fzf/src/history_test.go +68 -0
- data/lib/helpers/fzf/src/item.go +44 -0
- data/lib/helpers/fzf/src/item_test.go +23 -0
- data/lib/helpers/fzf/src/matcher.go +235 -0
- data/lib/helpers/fzf/src/merger.go +120 -0
- data/lib/helpers/fzf/src/merger_test.go +88 -0
- data/lib/helpers/fzf/src/options.go +1691 -0
- data/lib/helpers/fzf/src/options_test.go +457 -0
- data/lib/helpers/fzf/src/pattern.go +425 -0
- data/lib/helpers/fzf/src/pattern_test.go +209 -0
- data/lib/helpers/fzf/src/protector/protector.go +8 -0
- data/lib/helpers/fzf/src/protector/protector_openbsd.go +10 -0
- data/lib/helpers/fzf/src/reader.go +201 -0
- data/lib/helpers/fzf/src/reader_test.go +63 -0
- data/lib/helpers/fzf/src/result.go +243 -0
- data/lib/helpers/fzf/src/result_others.go +16 -0
- data/lib/helpers/fzf/src/result_test.go +159 -0
- data/lib/helpers/fzf/src/result_x86.go +16 -0
- data/lib/helpers/fzf/src/terminal.go +2832 -0
- data/lib/helpers/fzf/src/terminal_test.go +638 -0
- data/lib/helpers/fzf/src/terminal_unix.go +26 -0
- data/lib/helpers/fzf/src/terminal_windows.go +45 -0
- data/lib/helpers/fzf/src/tokenizer.go +253 -0
- data/lib/helpers/fzf/src/tokenizer_test.go +112 -0
- data/lib/helpers/fzf/src/tui/dummy.go +46 -0
- data/lib/helpers/fzf/src/tui/light.go +987 -0
- data/lib/helpers/fzf/src/tui/light_unix.go +110 -0
- data/lib/helpers/fzf/src/tui/light_windows.go +145 -0
- data/lib/helpers/fzf/src/tui/tcell.go +721 -0
- data/lib/helpers/fzf/src/tui/tcell_test.go +392 -0
- data/lib/helpers/fzf/src/tui/ttyname_unix.go +47 -0
- data/lib/helpers/fzf/src/tui/ttyname_windows.go +14 -0
- data/lib/helpers/fzf/src/tui/tui.go +625 -0
- data/lib/helpers/fzf/src/tui/tui_test.go +20 -0
- data/lib/helpers/fzf/src/util/atomicbool.go +34 -0
- data/lib/helpers/fzf/src/util/atomicbool_test.go +17 -0
- data/lib/helpers/fzf/src/util/chars.go +198 -0
- data/lib/helpers/fzf/src/util/chars_test.go +46 -0
- data/lib/helpers/fzf/src/util/eventbox.go +96 -0
- data/lib/helpers/fzf/src/util/eventbox_test.go +61 -0
- data/lib/helpers/fzf/src/util/slab.go +12 -0
- data/lib/helpers/fzf/src/util/util.go +138 -0
- data/lib/helpers/fzf/src/util/util_test.go +40 -0
- data/lib/helpers/fzf/src/util/util_unix.go +47 -0
- data/lib/helpers/fzf/src/util/util_windows.go +83 -0
- data/lib/helpers/fzf/test/fzf.vader +175 -0
- data/lib/helpers/fzf/test/test_go.rb +2626 -0
- data/lib/helpers/fzf/uninstall +117 -0
- data/scripts/generate_bash_completions.rb +6 -12
- data/scripts/generate_fish_completions.rb +7 -16
- data/scripts/generate_zsh_completions.rb +6 -15
- metadata +144 -9
@@ -0,0 +1,1001 @@
|
|
1
|
+
.ig
|
2
|
+
The MIT License (MIT)
|
3
|
+
|
4
|
+
Copyright (c) 2013-2021 Junegunn Choi
|
5
|
+
|
6
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
+
of this software and associated documentation files (the "Software"), to deal
|
8
|
+
in the Software without restriction, including without limitation the rights
|
9
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
+
copies of the Software, and to permit persons to whom the Software is
|
11
|
+
furnished to do so, subject to the following conditions:
|
12
|
+
|
13
|
+
The above copyright notice and this permission notice shall be included in
|
14
|
+
all copies or substantial portions of the Software.
|
15
|
+
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
+
THE SOFTWARE.
|
23
|
+
..
|
24
|
+
.TH fzf 1 "Nov 2021" "fzf 0.28.0" "fzf - a command-line fuzzy finder"
|
25
|
+
|
26
|
+
.SH NAME
|
27
|
+
fzf - a command-line fuzzy finder
|
28
|
+
|
29
|
+
.SH SYNOPSIS
|
30
|
+
fzf [options]
|
31
|
+
|
32
|
+
.SH DESCRIPTION
|
33
|
+
fzf is a general-purpose command-line fuzzy finder.
|
34
|
+
|
35
|
+
.SH OPTIONS
|
36
|
+
.SS Search mode
|
37
|
+
.TP
|
38
|
+
.B "-x, --extended"
|
39
|
+
Extended-search mode. Since 0.10.9, this is enabled by default. You can disable
|
40
|
+
it with \fB+x\fR or \fB--no-extended\fR.
|
41
|
+
.TP
|
42
|
+
.B "-e, --exact"
|
43
|
+
Enable exact-match
|
44
|
+
.TP
|
45
|
+
.B "-i"
|
46
|
+
Case-insensitive match (default: smart-case match)
|
47
|
+
.TP
|
48
|
+
.B "+i"
|
49
|
+
Case-sensitive match
|
50
|
+
.TP
|
51
|
+
.B "--literal"
|
52
|
+
Do not normalize latin script letters for matching.
|
53
|
+
.TP
|
54
|
+
.BI "--algo=" TYPE
|
55
|
+
Fuzzy matching algorithm (default: v2)
|
56
|
+
|
57
|
+
.br
|
58
|
+
.BR v2 " Optimal scoring algorithm (quality)"
|
59
|
+
.br
|
60
|
+
.BR v1 " Faster but not guaranteed to find the optimal result (performance)"
|
61
|
+
.br
|
62
|
+
|
63
|
+
.TP
|
64
|
+
.BI "-n, --nth=" "N[,..]"
|
65
|
+
Comma-separated list of field index expressions for limiting search scope.
|
66
|
+
See \fBFIELD INDEX EXPRESSION\fR for the details.
|
67
|
+
.TP
|
68
|
+
.BI "--with-nth=" "N[,..]"
|
69
|
+
Transform the presentation of each line using field index expressions
|
70
|
+
.TP
|
71
|
+
.BI "-d, --delimiter=" "STR"
|
72
|
+
Field delimiter regex for \fB--nth\fR and \fB--with-nth\fR (default: AWK-style)
|
73
|
+
.TP
|
74
|
+
.BI "--disabled"
|
75
|
+
Do not perform search. With this option, fzf becomes a simple selector
|
76
|
+
interface rather than a "fuzzy finder". You can later enable the search using
|
77
|
+
\fBenable-search\fR or \fBtoggle-search\fR action.
|
78
|
+
.SS Search result
|
79
|
+
.TP
|
80
|
+
.B "+s, --no-sort"
|
81
|
+
Do not sort the result
|
82
|
+
.TP
|
83
|
+
.B "--tac"
|
84
|
+
Reverse the order of the input
|
85
|
+
|
86
|
+
.RS
|
87
|
+
e.g.
|
88
|
+
\fBhistory | fzf --tac --no-sort\fR
|
89
|
+
.RE
|
90
|
+
.TP
|
91
|
+
.BI "--tiebreak=" "CRI[,..]"
|
92
|
+
Comma-separated list of sort criteria to apply when the scores are tied.
|
93
|
+
.br
|
94
|
+
|
95
|
+
.br
|
96
|
+
.BR length " Prefers line with shorter length"
|
97
|
+
.br
|
98
|
+
.BR begin " Prefers line with matched substring closer to the beginning"
|
99
|
+
.br
|
100
|
+
.BR end " Prefers line with matched substring closer to the end"
|
101
|
+
.br
|
102
|
+
.BR index " Prefers line that appeared earlier in the input stream"
|
103
|
+
.br
|
104
|
+
|
105
|
+
.br
|
106
|
+
- Each criterion should appear only once in the list
|
107
|
+
.br
|
108
|
+
- \fBindex\fR is only allowed at the end of the list
|
109
|
+
.br
|
110
|
+
- \fBindex\fR is implicitly appended to the list when not specified
|
111
|
+
.br
|
112
|
+
- Default is \fBlength\fR (or equivalently \fBlength\fR,index)
|
113
|
+
.br
|
114
|
+
- If \fBend\fR is found in the list, fzf will scan each line backwards
|
115
|
+
.SS Interface
|
116
|
+
.TP
|
117
|
+
.B "-m, --multi"
|
118
|
+
Enable multi-select with tab/shift-tab. It optionally takes an integer argument
|
119
|
+
which denotes the maximum number of items that can be selected.
|
120
|
+
.TP
|
121
|
+
.B "+m, --no-multi"
|
122
|
+
Disable multi-select
|
123
|
+
.TP
|
124
|
+
.B "--no-mouse"
|
125
|
+
Disable mouse
|
126
|
+
.TP
|
127
|
+
.BI "--bind=" "KEYBINDS"
|
128
|
+
Comma-separated list of custom key bindings. See \fBKEY/EVENT BINDINGS\fR for
|
129
|
+
the details.
|
130
|
+
.TP
|
131
|
+
.B "--cycle"
|
132
|
+
Enable cyclic scroll
|
133
|
+
.TP
|
134
|
+
.B "--keep-right"
|
135
|
+
Keep the right end of the line visible when it's too long. Effective only when
|
136
|
+
the query string is empty.
|
137
|
+
.TP
|
138
|
+
.BI "--scroll-off=" "LINES"
|
139
|
+
Number of screen lines to keep above or below when scrolling to the top or to
|
140
|
+
the bottom (default: 0).
|
141
|
+
.TP
|
142
|
+
.B "--no-hscroll"
|
143
|
+
Disable horizontal scroll
|
144
|
+
.TP
|
145
|
+
.BI "--hscroll-off=" "COLS"
|
146
|
+
Number of screen columns to keep to the right of the highlighted substring
|
147
|
+
(default: 10). Setting it to a large value will cause the text to be positioned
|
148
|
+
on the center of the screen.
|
149
|
+
.TP
|
150
|
+
.B "--filepath-word"
|
151
|
+
Make word-wise movements and actions respect path separators. The following
|
152
|
+
actions are affected:
|
153
|
+
|
154
|
+
\fBbackward-kill-word\fR
|
155
|
+
.br
|
156
|
+
\fBbackward-word\fR
|
157
|
+
.br
|
158
|
+
\fBforward-word\fR
|
159
|
+
.br
|
160
|
+
\fBkill-word\fR
|
161
|
+
.TP
|
162
|
+
.BI "--jump-labels=" "CHARS"
|
163
|
+
Label characters for \fBjump\fR and \fBjump-accept\fR
|
164
|
+
.SS Layout
|
165
|
+
.TP
|
166
|
+
.BI "--height=" "HEIGHT[%]"
|
167
|
+
Display fzf window below the cursor with the given height instead of using
|
168
|
+
the full screen.
|
169
|
+
.TP
|
170
|
+
.BI "--min-height=" "HEIGHT"
|
171
|
+
Minimum height when \fB--height\fR is given in percent (default: 10).
|
172
|
+
Ignored when \fB--height\fR is not specified.
|
173
|
+
.TP
|
174
|
+
.BI "--layout=" "LAYOUT"
|
175
|
+
Choose the layout (default: default)
|
176
|
+
|
177
|
+
.br
|
178
|
+
.BR default " Display from the bottom of the screen"
|
179
|
+
.br
|
180
|
+
.BR reverse " Display from the top of the screen"
|
181
|
+
.br
|
182
|
+
.BR reverse-list " Display from the top of the screen, prompt at the bottom"
|
183
|
+
.br
|
184
|
+
|
185
|
+
.TP
|
186
|
+
.B "--reverse"
|
187
|
+
A synonym for \fB--layout=reverse\fB
|
188
|
+
|
189
|
+
.TP
|
190
|
+
.BI "--border" [=STYLE]
|
191
|
+
Draw border around the finder
|
192
|
+
|
193
|
+
.br
|
194
|
+
.BR rounded " Border with rounded corners (default)"
|
195
|
+
.br
|
196
|
+
.BR sharp " Border with sharp corners"
|
197
|
+
.br
|
198
|
+
.BR horizontal " Horizontal lines above and below the finder"
|
199
|
+
.br
|
200
|
+
.BR vertical " Vertical lines on each side of the finder"
|
201
|
+
.br
|
202
|
+
.BR top
|
203
|
+
.br
|
204
|
+
.BR bottom
|
205
|
+
.br
|
206
|
+
.BR left
|
207
|
+
.br
|
208
|
+
.BR right
|
209
|
+
.br
|
210
|
+
.BR none
|
211
|
+
.br
|
212
|
+
|
213
|
+
.TP
|
214
|
+
.B "--no-unicode"
|
215
|
+
Use ASCII characters instead of Unicode box drawing characters to draw border
|
216
|
+
|
217
|
+
.TP
|
218
|
+
.BI "--margin=" MARGIN
|
219
|
+
Comma-separated expression for margins around the finder.
|
220
|
+
.br
|
221
|
+
|
222
|
+
.br
|
223
|
+
.RS
|
224
|
+
.BR TRBL " Same margin for top, right, bottom, and left"
|
225
|
+
.br
|
226
|
+
.BR TB,RL " Vertical, horizontal margin"
|
227
|
+
.br
|
228
|
+
.BR T,RL,B " Top, horizontal, bottom margin"
|
229
|
+
.br
|
230
|
+
.BR T,R,B,L " Top, right, bottom, left margin"
|
231
|
+
.br
|
232
|
+
|
233
|
+
.br
|
234
|
+
Each part can be given in absolute number or in percentage relative to the
|
235
|
+
terminal size with \fB%\fR suffix.
|
236
|
+
.br
|
237
|
+
|
238
|
+
.br
|
239
|
+
e.g.
|
240
|
+
\fBfzf --margin 10%
|
241
|
+
fzf --margin 1,5%\fR
|
242
|
+
.RE
|
243
|
+
.TP
|
244
|
+
.BI "--padding=" PADDING
|
245
|
+
Comma-separated expression for padding inside the border. Padding is
|
246
|
+
distinguishable from margin only when \fB--border\fR option is used.
|
247
|
+
.br
|
248
|
+
|
249
|
+
.br
|
250
|
+
e.g.
|
251
|
+
\fBfzf --margin 5% --padding 5% --border --preview 'cat {}' \\
|
252
|
+
--color bg:#222222,preview-bg:#333333\fR
|
253
|
+
|
254
|
+
.br
|
255
|
+
.RS
|
256
|
+
.BR TRBL " Same padding for top, right, bottom, and left"
|
257
|
+
.br
|
258
|
+
.BR TB,RL " Vertical, horizontal padding"
|
259
|
+
.br
|
260
|
+
.BR T,RL,B " Top, horizontal, bottom padding"
|
261
|
+
.br
|
262
|
+
.BR T,R,B,L " Top, right, bottom, left padding"
|
263
|
+
.br
|
264
|
+
.RE
|
265
|
+
|
266
|
+
.TP
|
267
|
+
.BI "--info=" "STYLE"
|
268
|
+
Determines the display style of finder info.
|
269
|
+
|
270
|
+
.br
|
271
|
+
.BR default " Display on the next line to the prompt"
|
272
|
+
.br
|
273
|
+
.BR inline " Display on the same line"
|
274
|
+
.br
|
275
|
+
.BR hidden " Do not display finder info"
|
276
|
+
.br
|
277
|
+
|
278
|
+
.TP
|
279
|
+
.B "--no-info"
|
280
|
+
A synonym for \fB--info=hidden\fB
|
281
|
+
|
282
|
+
.TP
|
283
|
+
.BI "--prompt=" "STR"
|
284
|
+
Input prompt (default: '> ')
|
285
|
+
.TP
|
286
|
+
.BI "--pointer=" "STR"
|
287
|
+
Pointer to the current line (default: '>')
|
288
|
+
.TP
|
289
|
+
.BI "--marker=" "STR"
|
290
|
+
Multi-select marker (default: '>')
|
291
|
+
.TP
|
292
|
+
.BI "--header=" "STR"
|
293
|
+
The given string will be printed as the sticky header. The lines are displayed
|
294
|
+
in the given order from top to bottom regardless of \fB--layout\fR option, and
|
295
|
+
are not affected by \fB--with-nth\fR. ANSI color codes are processed even when
|
296
|
+
\fB--ansi\fR is not set.
|
297
|
+
.TP
|
298
|
+
.BI "--header-lines=" "N"
|
299
|
+
The first N lines of the input are treated as the sticky header. When
|
300
|
+
\fB--with-nth\fR is set, the lines are transformed just like the other
|
301
|
+
lines that follow.
|
302
|
+
.TP
|
303
|
+
.B "--header-first"
|
304
|
+
Print header before the prompt line
|
305
|
+
.SS Display
|
306
|
+
.TP
|
307
|
+
.B "--ansi"
|
308
|
+
Enable processing of ANSI color codes
|
309
|
+
.TP
|
310
|
+
.BI "--tabstop=" SPACES
|
311
|
+
Number of spaces for a tab character (default: 8)
|
312
|
+
.TP
|
313
|
+
.BI "--color=" "[BASE_SCHEME][,COLOR_NAME[:ANSI_COLOR][:ANSI_ATTRIBUTES]]..."
|
314
|
+
Color configuration. The name of the base color scheme is followed by custom
|
315
|
+
color mappings.
|
316
|
+
|
317
|
+
.RS
|
318
|
+
.B BASE SCHEME:
|
319
|
+
(default: dark on 256-color terminal, otherwise 16)
|
320
|
+
|
321
|
+
\fBdark \fRColor scheme for dark 256-color terminal
|
322
|
+
\fBlight \fRColor scheme for light 256-color terminal
|
323
|
+
\fB16 \fRColor scheme for 16-color terminal
|
324
|
+
\fBbw \fRNo colors (equivalent to \fB--no-color\fR)
|
325
|
+
|
326
|
+
.B COLOR NAMES:
|
327
|
+
\fBfg \fRText
|
328
|
+
\fBbg \fRBackground
|
329
|
+
\fBpreview-fg \fRPreview window text
|
330
|
+
\fBpreview-bg \fRPreview window background
|
331
|
+
\fBhl \fRHighlighted substrings
|
332
|
+
\fBfg+ \fRText (current line)
|
333
|
+
\fBbg+ \fRBackground (current line)
|
334
|
+
\fBgutter \fRGutter on the left (defaults to \fBbg+\fR)
|
335
|
+
\fBhl+ \fRHighlighted substrings (current line)
|
336
|
+
\fBquery \fRQuery string
|
337
|
+
\fBdisabled \fRQuery string when search is disabled
|
338
|
+
\fBinfo \fRInfo line (match counters)
|
339
|
+
\fBborder \fRBorder around the window (\fB--border\fR and \fB--preview\fR)
|
340
|
+
\fBprompt \fRPrompt
|
341
|
+
\fBpointer \fRPointer to the current line
|
342
|
+
\fBmarker \fRMulti-select marker
|
343
|
+
\fBspinner \fRStreaming input indicator
|
344
|
+
\fBheader \fRHeader
|
345
|
+
|
346
|
+
.B ANSI COLORS:
|
347
|
+
\fB-1 \fRDefault terminal foreground/background color
|
348
|
+
\fB \fR(or the original color of the text)
|
349
|
+
\fB0 ~ 15 \fR16 base colors
|
350
|
+
\fBblack\fR
|
351
|
+
\fBred\fR
|
352
|
+
\fBgreen\fR
|
353
|
+
\fByellow\fR
|
354
|
+
\fBblue\fR
|
355
|
+
\fBmagenta\fR
|
356
|
+
\fBcyan\fR
|
357
|
+
\fBwhite\fR
|
358
|
+
\fBbright-black\fR (gray | grey)
|
359
|
+
\fBbright-red\fR
|
360
|
+
\fBbright-green\fR
|
361
|
+
\fBbright-yellow\fR
|
362
|
+
\fBbright-blue\fR
|
363
|
+
\fBbright-magenta\fR
|
364
|
+
\fBbright-cyan\fR
|
365
|
+
\fBbright-white\fR
|
366
|
+
\fB16 ~ 255 \fRANSI 256 colors
|
367
|
+
\fB#rrggbb \fR24-bit colors
|
368
|
+
|
369
|
+
.B ANSI ATTRIBUTES: (Only applies to foreground colors)
|
370
|
+
\fBregular \fRClears previously set attributes; should precede the other ones
|
371
|
+
\fBbold\fR
|
372
|
+
\fBunderline\fR
|
373
|
+
\fBreverse\fR
|
374
|
+
\fBdim\fR
|
375
|
+
\fBitalic\fR
|
376
|
+
|
377
|
+
.B EXAMPLES:
|
378
|
+
|
379
|
+
\fB# Seoul256 theme with 8-bit colors
|
380
|
+
# (https://github.com/junegunn/seoul256.vim)
|
381
|
+
fzf --color='bg:237,bg+:236,info:143,border:240,spinner:108' \\
|
382
|
+
--color='hl:65,fg:252,header:65,fg+:252' \\
|
383
|
+
--color='pointer:161,marker:168,prompt:110,hl+:108'
|
384
|
+
|
385
|
+
# Seoul256 theme with 24-bit colors
|
386
|
+
fzf --color='bg:#4B4B4B,bg+:#3F3F3F,info:#BDBB72,border:#6B6B6B,spinner:#98BC99' \\
|
387
|
+
--color='hl:#719872,fg:#D9D9D9,header:#719872,fg+:#D9D9D9' \\
|
388
|
+
--color='pointer:#E12672,marker:#E17899,prompt:#98BEDE,hl+:#98BC99'\fR
|
389
|
+
.RE
|
390
|
+
.TP
|
391
|
+
.B "--no-bold"
|
392
|
+
Do not use bold text
|
393
|
+
.TP
|
394
|
+
.B "--black"
|
395
|
+
Use black background
|
396
|
+
.SS History
|
397
|
+
.TP
|
398
|
+
.BI "--history=" "HISTORY_FILE"
|
399
|
+
Load search history from the specified file and update the file on completion.
|
400
|
+
When enabled, \fBCTRL-N\fR and \fBCTRL-P\fR are automatically remapped to
|
401
|
+
\fBnext-history\fR and \fBprevious-history\fR.
|
402
|
+
.TP
|
403
|
+
.BI "--history-size=" "N"
|
404
|
+
Maximum number of entries in the history file (default: 1000). The file is
|
405
|
+
automatically truncated when the number of the lines exceeds the value.
|
406
|
+
.SS Preview
|
407
|
+
.TP
|
408
|
+
.BI "--preview=" "COMMAND"
|
409
|
+
Execute the given command for the current line and display the result on the
|
410
|
+
preview window. \fB{}\fR in the command is the placeholder that is replaced to
|
411
|
+
the single-quoted string of the current line. To transform the replacement
|
412
|
+
string, specify field index expressions between the braces (See \fBFIELD INDEX
|
413
|
+
EXPRESSION\fR for the details).
|
414
|
+
|
415
|
+
.RS
|
416
|
+
e.g.
|
417
|
+
\fBfzf --preview='head -$LINES {}'
|
418
|
+
ls -l | fzf --preview="echo user={3} when={-4..-2}; cat {-1}" --header-lines=1\fR
|
419
|
+
|
420
|
+
fzf exports \fB$FZF_PREVIEW_LINES\fR and \fB$FZF_PREVIEW_COLUMNS\fR so that
|
421
|
+
they represent the exact size of the preview window. (It also overrides
|
422
|
+
\fB$LINES\fR and \fB$COLUMNS\fR with the same values but they can be reset
|
423
|
+
by the default shell, so prefer to refer to the ones with \fBFZF_PREVIEW_\fR
|
424
|
+
prefix.)
|
425
|
+
|
426
|
+
A placeholder expression starting with \fB+\fR flag will be replaced to the
|
427
|
+
space-separated list of the selected lines (or the current line if no selection
|
428
|
+
was made) individually quoted.
|
429
|
+
|
430
|
+
e.g.
|
431
|
+
\fBfzf --multi --preview='head -10 {+}'
|
432
|
+
git log --oneline | fzf --multi --preview 'git show {+1}'\fR
|
433
|
+
|
434
|
+
When using a field index expression, leading and trailing whitespace is stripped
|
435
|
+
from the replacement string. To preserve the whitespace, use the \fBs\fR flag.
|
436
|
+
|
437
|
+
Also, \fB{q}\fR is replaced to the current query string, and \fB{n}\fR is
|
438
|
+
replaced to zero-based ordinal index of the line. Use \fB{+n}\fR if you want
|
439
|
+
all index numbers when multiple lines are selected.
|
440
|
+
|
441
|
+
A placeholder expression with \fBf\fR flag is replaced to the path of
|
442
|
+
a temporary file that holds the evaluated list. This is useful when you
|
443
|
+
multi-select a large number of items and the length of the evaluated string may
|
444
|
+
exceed \fBARG_MAX\fR.
|
445
|
+
|
446
|
+
e.g.
|
447
|
+
\fB# Press CTRL-A to select 100K items and see the sum of all the numbers.
|
448
|
+
# This won't work properly without 'f' flag due to ARG_MAX limit.
|
449
|
+
seq 100000 | fzf --multi --bind ctrl-a:select-all \\
|
450
|
+
--preview "awk '{sum+=\$1} END {print sum}' {+f}"\fR
|
451
|
+
|
452
|
+
Note that you can escape a placeholder pattern by prepending a backslash.
|
453
|
+
|
454
|
+
Preview window will be updated even when there is no match for the current
|
455
|
+
query if any of the placeholder expressions evaluates to a non-empty string.
|
456
|
+
|
457
|
+
Since 0.24.0, fzf can render partial preview content before the preview command
|
458
|
+
completes. ANSI escape sequence for clearing the display (\fBCSI 2 J\fR) is
|
459
|
+
supported, so you can use it to implement preview window that is constantly
|
460
|
+
updating.
|
461
|
+
|
462
|
+
e.g.
|
463
|
+
\fBfzf --preview 'for i in $(seq 100000); do
|
464
|
+
(( i % 200 == 0 )) && printf "\\033[2J"
|
465
|
+
echo "$i"
|
466
|
+
sleep 0.01
|
467
|
+
done'\fR
|
468
|
+
.RE
|
469
|
+
.TP
|
470
|
+
.BI "--preview-window=" "[POSITION][,SIZE[%]][,border-BORDER_OPT][,[no]wrap][,[no]follow][,[no]cycle][,[no]hidden][,+SCROLL[OFFSETS][/DENOM]][,~HEADER_LINES][,default]"
|
471
|
+
|
472
|
+
.RS
|
473
|
+
.B POSITION: (default: right)
|
474
|
+
\fBup
|
475
|
+
\fBdown
|
476
|
+
\fBleft
|
477
|
+
\fBright
|
478
|
+
|
479
|
+
\fRDetermines the layout of the preview window.
|
480
|
+
|
481
|
+
* If the argument contains \fB:hidden\fR, the preview window will be hidden by
|
482
|
+
default until \fBtoggle-preview\fR action is triggered.
|
483
|
+
|
484
|
+
* If size is given as 0, preview window will not be visible, but fzf will still
|
485
|
+
execute the command in the background.
|
486
|
+
|
487
|
+
* Long lines are truncated by default. Line wrap can be enabled with
|
488
|
+
\fB:wrap\fR flag.
|
489
|
+
|
490
|
+
* Preview window will automatically scroll to the bottom when \fB:follow\fR
|
491
|
+
flag is set, similarly to how \fBtail -f\fR works.
|
492
|
+
|
493
|
+
.RS
|
494
|
+
e.g.
|
495
|
+
\fBfzf --preview-window follow --preview 'for i in $(seq 100000); do
|
496
|
+
echo "$i"
|
497
|
+
sleep 0.01
|
498
|
+
(( i % 300 == 0 )) && printf "\\033[2J"
|
499
|
+
done'\fR
|
500
|
+
.RE
|
501
|
+
|
502
|
+
* Cyclic scrolling is enabled with \fB:cycle\fR flag.
|
503
|
+
|
504
|
+
* To change the style of the border of the preview window, specify one of
|
505
|
+
the options for \fB--border\fR with \fBborder-\fR prefix.
|
506
|
+
e.g. \fBborder-rounded\fR (border with rounded edges, default),
|
507
|
+
\fBborder-sharp\fR (border with sharp edges), \fBborder-left\fR,
|
508
|
+
\fBborder-none\fR, etc.
|
509
|
+
|
510
|
+
* \fB[:+SCROLL[OFFSETS][/DENOM]]\fR determines the initial scroll offset of the
|
511
|
+
preview window.
|
512
|
+
|
513
|
+
- \fBSCROLL\fR can be either a numeric integer or a single-field index expression that refers to a numeric integer.
|
514
|
+
|
515
|
+
- The optional \fBOFFSETS\fR part is for adjusting the base offset. It should be given as a series of signed integers (\fB-INTEGER\fR or \fB+INTEGER\fR).
|
516
|
+
|
517
|
+
- The final \fB/DENOM\fR part is for specifying a fraction of the preview window height.
|
518
|
+
|
519
|
+
* \fB~HEADER_LINES\fR keeps the top N lines as the fixed header so that they
|
520
|
+
are always visible.
|
521
|
+
|
522
|
+
* \fBdefault\fR resets all options previously set to the default.
|
523
|
+
|
524
|
+
.RS
|
525
|
+
e.g.
|
526
|
+
\fB# Non-default scroll window positions and sizes
|
527
|
+
fzf --preview="head {}" --preview-window=up,30%
|
528
|
+
fzf --preview="file {}" --preview-window=down,1
|
529
|
+
|
530
|
+
# Initial scroll offset is set to the line number of each line of
|
531
|
+
# git grep output *minus* 5 lines (-5)
|
532
|
+
git grep --line-number '' |
|
533
|
+
fzf --delimiter : --preview 'nl {1}' --preview-window '+{2}-5'
|
534
|
+
|
535
|
+
# Preview with bat, matching line in the middle of the window below
|
536
|
+
# the fixed header of the top 3 lines
|
537
|
+
#
|
538
|
+
# ~3 Top 3 lines as the fixed header
|
539
|
+
# +{2} Base scroll offset extracted from the second field
|
540
|
+
# +3 Extra offset to compensate for the 3-line header
|
541
|
+
# /2 Put in the middle of the preview area
|
542
|
+
#
|
543
|
+
git grep --line-number '' |
|
544
|
+
fzf --delimiter : \\
|
545
|
+
--preview 'bat --style=full --color=always --highlight-line {2} {1}' \\
|
546
|
+
--preview-window '~3,+{2}+3/2'
|
547
|
+
|
548
|
+
# Display top 3 lines as the fixed header
|
549
|
+
fzf --preview 'bat --style=full --color=always {}' --preview-window '~3'\fR
|
550
|
+
.RE
|
551
|
+
|
552
|
+
.SS Scripting
|
553
|
+
.TP
|
554
|
+
.BI "-q, --query=" "STR"
|
555
|
+
Start the finder with the given query
|
556
|
+
.TP
|
557
|
+
.B "-1, --select-1"
|
558
|
+
If there is only one match for the initial query (\fB--query\fR), do not start
|
559
|
+
interactive finder and automatically select the only match
|
560
|
+
.TP
|
561
|
+
.B "-0, --exit-0"
|
562
|
+
If there is no match for the initial query (\fB--query\fR), do not start
|
563
|
+
interactive finder and exit immediately
|
564
|
+
.TP
|
565
|
+
.BI "-f, --filter=" "STR"
|
566
|
+
Filter mode. Do not start interactive finder. When used with \fB--no-sort\fR,
|
567
|
+
fzf becomes a fuzzy-version of grep.
|
568
|
+
.TP
|
569
|
+
.B "--print-query"
|
570
|
+
Print query as the first line
|
571
|
+
.TP
|
572
|
+
.BI "--expect=" "KEY[,..]"
|
573
|
+
Comma-separated list of keys that can be used to complete fzf in addition to
|
574
|
+
the default enter key. When this option is set, fzf will print the name of the
|
575
|
+
key pressed as the first line of its output (or as the second line if
|
576
|
+
\fB--print-query\fR is also used). The line will be empty if fzf is completed
|
577
|
+
with the default enter key. If \fB--expect\fR option is specified multiple
|
578
|
+
times, fzf will expect the union of the keys. \fB--no-expect\fR will clear the
|
579
|
+
list.
|
580
|
+
|
581
|
+
.RS
|
582
|
+
e.g.
|
583
|
+
\fBfzf --expect=ctrl-v,ctrl-t,alt-s --expect=f1,f2,~,@\fR
|
584
|
+
.RE
|
585
|
+
.TP
|
586
|
+
.B "--read0"
|
587
|
+
Read input delimited by ASCII NUL characters instead of newline characters
|
588
|
+
.TP
|
589
|
+
.B "--print0"
|
590
|
+
Print output delimited by ASCII NUL characters instead of newline characters
|
591
|
+
.TP
|
592
|
+
.B "--no-clear"
|
593
|
+
Do not clear finder interface on exit. If fzf was started in full screen mode,
|
594
|
+
it will not switch back to the original screen, so you'll have to manually run
|
595
|
+
\fBtput rmcup\fR to return. This option can be used to avoid flickering of the
|
596
|
+
screen when your application needs to start fzf multiple times in order.
|
597
|
+
.TP
|
598
|
+
.B "--sync"
|
599
|
+
Synchronous search for multi-staged filtering. If specified, fzf will launch
|
600
|
+
ncurses finder only after the input stream is complete.
|
601
|
+
|
602
|
+
.RS
|
603
|
+
e.g. \fBfzf --multi | fzf --sync\fR
|
604
|
+
.RE
|
605
|
+
.TP
|
606
|
+
.B "--version"
|
607
|
+
Display version information and exit
|
608
|
+
|
609
|
+
.TP
|
610
|
+
Note that most options have the opposite versions with \fB--no-\fR prefix.
|
611
|
+
|
612
|
+
.SH ENVIRONMENT VARIABLES
|
613
|
+
.TP
|
614
|
+
.B FZF_DEFAULT_COMMAND
|
615
|
+
Default command to use when input is tty. On *nix systems, fzf runs the command
|
616
|
+
with \fB$SHELL -c\fR if \fBSHELL\fR is set, otherwise with \fBsh -c\fR, so in
|
617
|
+
this case make sure that the command is POSIX-compliant.
|
618
|
+
.TP
|
619
|
+
.B FZF_DEFAULT_OPTS
|
620
|
+
Default options. e.g. \fBexport FZF_DEFAULT_OPTS="--extended --cycle"\fR
|
621
|
+
|
622
|
+
.SH EXIT STATUS
|
623
|
+
.BR 0 " Normal exit"
|
624
|
+
.br
|
625
|
+
.BR 1 " No match"
|
626
|
+
.br
|
627
|
+
.BR 2 " Error"
|
628
|
+
.br
|
629
|
+
.BR 130 " Interrupted with \fBCTRL-C\fR or \fBESC\fR"
|
630
|
+
|
631
|
+
.SH FIELD INDEX EXPRESSION
|
632
|
+
|
633
|
+
A field index expression can be a non-zero integer or a range expression
|
634
|
+
([BEGIN]..[END]). \fB--nth\fR and \fB--with-nth\fR take a comma-separated list
|
635
|
+
of field index expressions.
|
636
|
+
|
637
|
+
.SS Examples
|
638
|
+
.BR 1 " The 1st field"
|
639
|
+
.br
|
640
|
+
.BR 2 " The 2nd field"
|
641
|
+
.br
|
642
|
+
.BR -1 " The last field"
|
643
|
+
.br
|
644
|
+
.BR -2 " The 2nd to last field"
|
645
|
+
.br
|
646
|
+
.BR 3..5 " From the 3rd field to the 5th field"
|
647
|
+
.br
|
648
|
+
.BR 2.. " From the 2nd field to the last field"
|
649
|
+
.br
|
650
|
+
.BR ..-3 " From the 1st field to the 3rd to the last field"
|
651
|
+
.br
|
652
|
+
.BR .. " All the fields"
|
653
|
+
.br
|
654
|
+
|
655
|
+
.SH EXTENDED SEARCH MODE
|
656
|
+
|
657
|
+
Unless specified otherwise, fzf will start in "extended-search mode". In this
|
658
|
+
mode, you can specify multiple patterns delimited by spaces, such as: \fB'wild
|
659
|
+
^music .mp3$ sbtrkt !rmx\fR
|
660
|
+
|
661
|
+
You can prepend a backslash to a space (\fB\\ \fR) to match a literal space
|
662
|
+
character.
|
663
|
+
|
664
|
+
.SS Exact-match (quoted)
|
665
|
+
A term that is prefixed by a single-quote character (\fB'\fR) is interpreted as
|
666
|
+
an "exact-match" (or "non-fuzzy") term. fzf will search for the exact
|
667
|
+
occurrences of the string.
|
668
|
+
|
669
|
+
.SS Anchored-match
|
670
|
+
A term can be prefixed by \fB^\fR, or suffixed by \fB$\fR to become an
|
671
|
+
anchored-match term. Then fzf will search for the lines that start with or end
|
672
|
+
with the given string. An anchored-match term is also an exact-match term.
|
673
|
+
|
674
|
+
.SS Negation
|
675
|
+
If a term is prefixed by \fB!\fR, fzf will exclude the lines that satisfy the
|
676
|
+
term from the result. In this case, fzf performs exact match by default.
|
677
|
+
|
678
|
+
.SS Exact-match by default
|
679
|
+
If you don't prefer fuzzy matching and do not wish to "quote" (prefixing with
|
680
|
+
\fB'\fR) every word, start fzf with \fB-e\fR or \fB--exact\fR option. Note that
|
681
|
+
when \fB--exact\fR is set, \fB'\fR-prefix "unquotes" the term.
|
682
|
+
|
683
|
+
.SS OR operator
|
684
|
+
A single bar character term acts as an OR operator. For example, the following
|
685
|
+
query matches entries that start with \fBcore\fR and end with either \fBgo\fR,
|
686
|
+
\fBrb\fR, or \fBpy\fR.
|
687
|
+
|
688
|
+
e.g. \fB^core go$ | rb$ | py$\fR
|
689
|
+
|
690
|
+
.SH KEY/EVENT BINDINGS
|
691
|
+
\fB--bind\fR option allows you to bind \fBa key\fR or \fBan event\fR to one or
|
692
|
+
more \fBactions\fR. You can use it to customize key bindings or implement
|
693
|
+
dynamic behaviors.
|
694
|
+
|
695
|
+
\fB--bind\fR takes a comma-separated list of binding expressions. Each binding
|
696
|
+
expression is \fBKEY:ACTION\fR or \fBEVENT:ACTION\fR.
|
697
|
+
|
698
|
+
e.g.
|
699
|
+
\fBfzf --bind=ctrl-j:accept,ctrl-k:kill-line\fR
|
700
|
+
|
701
|
+
.SS AVAILABLE KEYS: (SYNONYMS)
|
702
|
+
\fIctrl-[a-z]\fR
|
703
|
+
.br
|
704
|
+
\fIctrl-space\fR
|
705
|
+
.br
|
706
|
+
\fIctrl-\\\fR
|
707
|
+
.br
|
708
|
+
\fIctrl-]\fR
|
709
|
+
.br
|
710
|
+
\fIctrl-^\fR (\fIctrl-6\fR)
|
711
|
+
.br
|
712
|
+
\fIctrl-/\fR (\fIctrl-_\fR)
|
713
|
+
.br
|
714
|
+
\fIctrl-alt-[a-z]\fR
|
715
|
+
.br
|
716
|
+
\fIalt-[*]\fR (Any case-sensitive single character is allowed)
|
717
|
+
.br
|
718
|
+
\fIf[1-12]\fR
|
719
|
+
.br
|
720
|
+
\fIenter\fR (\fIreturn\fR \fIctrl-m\fR)
|
721
|
+
.br
|
722
|
+
\fIspace\fR
|
723
|
+
.br
|
724
|
+
\fIbspace\fR (\fIbs\fR)
|
725
|
+
.br
|
726
|
+
\fIalt-up\fR
|
727
|
+
.br
|
728
|
+
\fIalt-down\fR
|
729
|
+
.br
|
730
|
+
\fIalt-left\fR
|
731
|
+
.br
|
732
|
+
\fIalt-right\fR
|
733
|
+
.br
|
734
|
+
\fIalt-enter\fR
|
735
|
+
.br
|
736
|
+
\fIalt-space\fR
|
737
|
+
.br
|
738
|
+
\fIalt-bspace\fR (\fIalt-bs\fR)
|
739
|
+
.br
|
740
|
+
\fItab\fR
|
741
|
+
.br
|
742
|
+
\fIbtab\fR (\fIshift-tab\fR)
|
743
|
+
.br
|
744
|
+
\fIesc\fR
|
745
|
+
.br
|
746
|
+
\fIdel\fR
|
747
|
+
.br
|
748
|
+
\fIup\fR
|
749
|
+
.br
|
750
|
+
\fIdown\fR
|
751
|
+
.br
|
752
|
+
\fIleft\fR
|
753
|
+
.br
|
754
|
+
\fIright\fR
|
755
|
+
.br
|
756
|
+
\fIhome\fR
|
757
|
+
.br
|
758
|
+
\fIend\fR
|
759
|
+
.br
|
760
|
+
\fIinsert\fR
|
761
|
+
.br
|
762
|
+
\fIpgup\fR (\fIpage-up\fR)
|
763
|
+
.br
|
764
|
+
\fIpgdn\fR (\fIpage-down\fR)
|
765
|
+
.br
|
766
|
+
\fIshift-up\fR
|
767
|
+
.br
|
768
|
+
\fIshift-down\fR
|
769
|
+
.br
|
770
|
+
\fIshift-left\fR
|
771
|
+
.br
|
772
|
+
\fIshift-right\fR
|
773
|
+
.br
|
774
|
+
\fIalt-shift-up\fR
|
775
|
+
.br
|
776
|
+
\fIalt-shift-down\fR
|
777
|
+
.br
|
778
|
+
\fIalt-shift-left\fR
|
779
|
+
.br
|
780
|
+
\fIalt-shift-right\fR
|
781
|
+
.br
|
782
|
+
\fIleft-click\fR
|
783
|
+
.br
|
784
|
+
\fIright-click\fR
|
785
|
+
.br
|
786
|
+
\fIdouble-click\fR
|
787
|
+
.br
|
788
|
+
or any single character
|
789
|
+
|
790
|
+
.SS AVAILABLE EVENTS:
|
791
|
+
\fIchange\fR
|
792
|
+
.RS
|
793
|
+
Triggered whenever the query string is changed
|
794
|
+
|
795
|
+
e.g.
|
796
|
+
\fB# Move cursor to the first entry whenever the query is changed
|
797
|
+
fzf --bind change:first\fR
|
798
|
+
.RE
|
799
|
+
|
800
|
+
\fIbackward-eof\fR
|
801
|
+
.RS
|
802
|
+
Triggered when the query string is already empty and you try to delete it
|
803
|
+
backward.
|
804
|
+
|
805
|
+
e.g.
|
806
|
+
\fBfzf --bind backward-eof:abort\fR
|
807
|
+
.RE
|
808
|
+
|
809
|
+
.SS AVAILABLE ACTIONS:
|
810
|
+
A key or an event can be bound to one or more of the following actions.
|
811
|
+
|
812
|
+
\fBACTION: DEFAULT BINDINGS (NOTES):
|
813
|
+
\fBabort\fR \fIctrl-c ctrl-g ctrl-q esc\fR
|
814
|
+
\fBaccept\fR \fIenter double-click\fR
|
815
|
+
\fBaccept-non-empty\fR (same as \fBaccept\fR except that it prevents fzf from exiting without selection)
|
816
|
+
\fBbackward-char\fR \fIctrl-b left\fR
|
817
|
+
\fBbackward-delete-char\fR \fIctrl-h bspace\fR
|
818
|
+
\fBbackward-delete-char/eof\fR (same as \fBbackward-delete-char\fR except aborts fzf if query is empty)
|
819
|
+
\fBbackward-kill-word\fR \fIalt-bs\fR
|
820
|
+
\fBbackward-word\fR \fIalt-b shift-left\fR
|
821
|
+
\fBbeginning-of-line\fR \fIctrl-a home\fR
|
822
|
+
\fBcancel\fR (clear query string if not empty, abort fzf otherwise)
|
823
|
+
\fBchange-prompt(...)\fR (change prompt to the given string)
|
824
|
+
\fBclear-screen\fR \fIctrl-l\fR
|
825
|
+
\fBclear-selection\fR (clear multi-selection)
|
826
|
+
\fBclose\fR (close preview window if open, abort fzf otherwise)
|
827
|
+
\fBclear-query\fR (clear query string)
|
828
|
+
\fBdelete-char\fR \fIdel\fR
|
829
|
+
\fBdelete-char/eof\fR \fIctrl-d\fR (same as \fBdelete-char\fR except aborts fzf if query is empty)
|
830
|
+
\fBdeselect\fR
|
831
|
+
\fBdeselect-all\fR (deselect all matches)
|
832
|
+
\fBdisable-search\fR (disable search functionality)
|
833
|
+
\fBdown\fR \fIctrl-j ctrl-n down\fR
|
834
|
+
\fBenable-search\fR (enable search functionality)
|
835
|
+
\fBend-of-line\fR \fIctrl-e end\fR
|
836
|
+
\fBexecute(...)\fR (see below for the details)
|
837
|
+
\fBexecute-silent(...)\fR (see below for the details)
|
838
|
+
\fBfirst\fR (move to the first match)
|
839
|
+
\fBforward-char\fR \fIctrl-f right\fR
|
840
|
+
\fBforward-word\fR \fIalt-f shift-right\fR
|
841
|
+
\fBignore\fR
|
842
|
+
\fBjump\fR (EasyMotion-like 2-keystroke movement)
|
843
|
+
\fBjump-accept\fR (jump and accept)
|
844
|
+
\fBkill-line\fR
|
845
|
+
\fBkill-word\fR \fIalt-d\fR
|
846
|
+
\fBlast\fR (move to the last match)
|
847
|
+
\fBnext-history\fR (\fIctrl-n\fR on \fB--history\fR)
|
848
|
+
\fBpage-down\fR \fIpgdn\fR
|
849
|
+
\fBpage-up\fR \fIpgup\fR
|
850
|
+
\fBhalf-page-down\fR
|
851
|
+
\fBhalf-page-up\fR
|
852
|
+
\fBpreview(...)\fR (see below for the details)
|
853
|
+
\fBpreview-down\fR \fIshift-down\fR
|
854
|
+
\fBpreview-up\fR \fIshift-up\fR
|
855
|
+
\fBpreview-page-down\fR
|
856
|
+
\fBpreview-page-up\fR
|
857
|
+
\fBpreview-half-page-down\fR
|
858
|
+
\fBpreview-half-page-up\fR
|
859
|
+
\fBpreview-bottom\fR
|
860
|
+
\fBpreview-top\fR
|
861
|
+
\fBprevious-history\fR (\fIctrl-p\fR on \fB--history\fR)
|
862
|
+
\fBprint-query\fR (print query and exit)
|
863
|
+
\fBput\fR (put the character to the prompt)
|
864
|
+
\fBrefresh-preview\fR
|
865
|
+
\fBreload(...)\fR (see below for the details)
|
866
|
+
\fBreplace-query\fR (replace query string with the current selection)
|
867
|
+
\fBselect\fR
|
868
|
+
\fBselect-all\fR (select all matches)
|
869
|
+
\fBtoggle\fR (\fIright-click\fR)
|
870
|
+
\fBtoggle-all\fR (toggle all matches)
|
871
|
+
\fBtoggle+down\fR \fIctrl-i (tab)\fR
|
872
|
+
\fBtoggle-in\fR (\fB--layout=reverse*\fR ? \fBtoggle+up\fR : \fBtoggle+down\fR)
|
873
|
+
\fBtoggle-out\fR (\fB--layout=reverse*\fR ? \fBtoggle+down\fR : \fBtoggle+up\fR)
|
874
|
+
\fBtoggle-preview\fR
|
875
|
+
\fBtoggle-preview-wrap\fR
|
876
|
+
\fBtoggle-search\fR (toggle search functionality)
|
877
|
+
\fBtoggle-sort\fR
|
878
|
+
\fBtoggle+up\fR \fIbtab (shift-tab)\fR
|
879
|
+
\fBunbind(...)\fR (unbind bindings)
|
880
|
+
\fBunix-line-discard\fR \fIctrl-u\fR
|
881
|
+
\fBunix-word-rubout\fR \fIctrl-w\fR
|
882
|
+
\fBup\fR \fIctrl-k ctrl-p up\fR
|
883
|
+
\fByank\fR \fIctrl-y\fR
|
884
|
+
|
885
|
+
.SS ACTION COMPOSITION
|
886
|
+
|
887
|
+
Multiple actions can be chained using \fB+\fR separator.
|
888
|
+
|
889
|
+
e.g.
|
890
|
+
\fBfzf --multi --bind 'ctrl-a:select-all+accept'\fR
|
891
|
+
\fBfzf --multi --bind 'ctrl-a:select-all' --bind 'ctrl-a:+accept'\fR
|
892
|
+
|
893
|
+
.SS ACTION ARGUMENT
|
894
|
+
|
895
|
+
An action denoted with \fB(...)\fR suffix takes an argument.
|
896
|
+
|
897
|
+
e.g.
|
898
|
+
\fBfzf --bind 'ctrl-a:change-prompt(NewPrompt> )'\fR
|
899
|
+
\fBfzf --bind 'ctrl-v:preview(cat {})' --preview-window hidden\fR
|
900
|
+
|
901
|
+
If the argument contains parentheses, fzf may fail to parse the expression. In
|
902
|
+
that case, you can use any of the following alternative notations to avoid
|
903
|
+
parse errors.
|
904
|
+
|
905
|
+
\fBaction-name[...]\fR
|
906
|
+
\fBaction-name~...~\fR
|
907
|
+
\fBaction-name!...!\fR
|
908
|
+
\fBaction-name@...@\fR
|
909
|
+
\fBaction-name#...#\fR
|
910
|
+
\fBaction-name$...$\fR
|
911
|
+
\fBaction-name%...%\fR
|
912
|
+
\fBaction-name^...^\fR
|
913
|
+
\fBaction-name&...&\fR
|
914
|
+
\fBaction-name*...*\fR
|
915
|
+
\fBaction-name;...;\fR
|
916
|
+
\fBaction-name/.../\fR
|
917
|
+
\fBaction-name|...|\fR
|
918
|
+
\fBaction-name:...\fR
|
919
|
+
.RS
|
920
|
+
The last one is the special form that frees you from parse errors as it does
|
921
|
+
not expect the closing character. The catch is that it should be the last one
|
922
|
+
in the comma-separated list of key-action pairs.
|
923
|
+
.RE
|
924
|
+
|
925
|
+
.SS COMMAND EXECUTION
|
926
|
+
|
927
|
+
With \fBexecute(...)\fR action, you can execute arbitrary commands without
|
928
|
+
leaving fzf. For example, you can turn fzf into a simple file browser by
|
929
|
+
binding \fBenter\fR key to \fBless\fR command like follows.
|
930
|
+
|
931
|
+
\fBfzf --bind "enter:execute(less {})"\fR
|
932
|
+
|
933
|
+
You can use the same placeholder expressions as in \fB--preview\fR.
|
934
|
+
|
935
|
+
fzf switches to the alternate screen when executing a command. However, if the
|
936
|
+
command is expected to complete quickly, and you are not interested in its
|
937
|
+
output, you might want to use \fBexecute-silent\fR instead, which silently
|
938
|
+
executes the command without the switching. Note that fzf will not be
|
939
|
+
responsive until the command is complete. For asynchronous execution, start
|
940
|
+
your command as a background process (i.e. appending \fB&\fR).
|
941
|
+
|
942
|
+
On *nix systems, fzf runs the command with \fB$SHELL -c\fR if \fBSHELL\fR is
|
943
|
+
set, otherwise with \fBsh -c\fR, so in this case make sure that the command is
|
944
|
+
POSIX-compliant.
|
945
|
+
|
946
|
+
.SS RELOAD INPUT
|
947
|
+
|
948
|
+
\fBreload(...)\fR action is used to dynamically update the input list
|
949
|
+
without restarting fzf. It takes the same command template with placeholder
|
950
|
+
expressions as \fBexecute(...)\fR.
|
951
|
+
|
952
|
+
See \fIhttps://github.com/junegunn/fzf/issues/1750\fR for more info.
|
953
|
+
|
954
|
+
e.g.
|
955
|
+
\fB# Update the list of processes by pressing CTRL-R
|
956
|
+
ps -ef | fzf --bind 'ctrl-r:reload(ps -ef)' --header 'Press CTRL-R to reload' \\
|
957
|
+
--header-lines=1 --layout=reverse
|
958
|
+
|
959
|
+
# Integration with ripgrep
|
960
|
+
RG_PREFIX="rg --column --line-number --no-heading --color=always --smart-case "
|
961
|
+
INITIAL_QUERY="foobar"
|
962
|
+
FZF_DEFAULT_COMMAND="$RG_PREFIX '$INITIAL_QUERY'" \\
|
963
|
+
fzf --bind "change:reload:$RG_PREFIX {q} || true" \\
|
964
|
+
--ansi --disabled --query "$INITIAL_QUERY"\fR
|
965
|
+
|
966
|
+
.SS PREVIEW BINDING
|
967
|
+
|
968
|
+
With \fBpreview(...)\fR action, you can specify multiple different preview
|
969
|
+
commands in addition to the default preview command given by \fB--preview\fR
|
970
|
+
option.
|
971
|
+
|
972
|
+
e.g.
|
973
|
+
|
974
|
+
# Default preview command with an extra preview binding
|
975
|
+
fzf --preview 'file {}' --bind '?:preview:cat {}'
|
976
|
+
|
977
|
+
# A preview binding with no default preview command
|
978
|
+
# (Preview window is initially empty)
|
979
|
+
fzf --bind '?:preview:cat {}'
|
980
|
+
|
981
|
+
# Preview window hidden by default, it appears when you first hit '?'
|
982
|
+
fzf --bind '?:preview:cat {}' --preview-window hidden
|
983
|
+
|
984
|
+
.SH AUTHOR
|
985
|
+
Junegunn Choi (\fIjunegunn.c@gmail.com\fR)
|
986
|
+
|
987
|
+
.SH SEE ALSO
|
988
|
+
.B Project homepage:
|
989
|
+
.RS
|
990
|
+
.I https://github.com/junegunn/fzf
|
991
|
+
.RE
|
992
|
+
.br
|
993
|
+
|
994
|
+
.br
|
995
|
+
.B Extra Vim plugin:
|
996
|
+
.RS
|
997
|
+
.I https://github.com/junegunn/fzf.vim
|
998
|
+
.RE
|
999
|
+
|
1000
|
+
.SH LICENSE
|
1001
|
+
MIT
|