Skip to content
Myr

0.13.0

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Junegunn Choi · committed by Junegunn Choi · parent 2bbc120 · Browse files · 4 files+227 added−194 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

4 files+227 added−194 removed

  • other:+227 added−194 removed

4 files+227 added−194 removed

modified:man/man1/fzf.1+217 added-188 removed
19 unmodified lines
20LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,21OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN22THE SOFTWARE.23..24.TH fzf 1 "May 2016" "fzf 0.12.2" "fzf - a command-line fuzzy finder"24.TH fzf 1 "Jun 2016" "fzf 0.13.0" "fzf - a command-line fuzzy finder"2526.SH NAME27fzf - a command-line fuzzy finder28
20 unmodified lines
49Case-sensitive match50.TP51.BI "-n, --nth=" "N[,..]"52Comma-separated list of field index expressions for limiting search scope.53See \fBFIELD INDEX EXPRESSION\fR for details.53See \fBFIELD INDEX EXPRESSION\fR for the details.54.TP55.BI "--with-nth=" "N[,..]"56Transform each item using index expressions within finder56Transform the presentation of each line using field index expressions57.TP58.BI "-d, --delimiter=" "STR"59Field delimiter regex for \fB--nth\fR and \fB--with-nth\fR (default: AWK-style)60.SS Search result
2 unmodified lines
63Do not sort the result64.TP65.B "--tac"66Reverse the order of the input6768.RS69e.g. \fBhistory | fzf --tac --no-sort\fR70.RE71.TP
1 unmodified line
73Comma-separated list of sort criteria to apply when the scores are tied.74.br7576.br76.BR length " Prefers item with shorter length"77.BR length " Prefers line with shorter length"78.br78.BR begin " Prefers item with matched substring closer to the beginning"79.BR begin " Prefers line with matched substring closer to the beginning"80.br80.BR end " Prefers item with matched substring closer to the end"81.BR end " Prefers line with matched substring closer to the end"82.br82.BR index " Prefers item that appeared earlier in the input stream"83.BR index " Prefers line that appeared earlier in the input stream"84.br8586.br87- Each criterion should appear only once in the list
2 unmodified lines
90.br91- \fBindex\fR is implicitly appended to the list when not specified92.br93- Default is \fBlength\fR (or equivalently \fBlength\fR,index)94.br95- If \fBend\fR is found in the list, fzf will scan each line backwards96.SS Interface97.TP98.B "-m, --multi"99Enable multi-select with tab/shift-tab100.TP98.B "--ansi"99Enable processing of ANSI color codes100.TP101.B "--no-mouse"102Disable mouse103.TP104.BI "--color=" "[BASE_SCHEME][,COLOR:ANSI]"105Color configuration. The name of the base color scheme is followed by custom106color mappings. Ansi color code of -1 denotes terminal default107foreground/background color.108109.RS110e.g. \fBfzf --color=bg+:24\fR111 \fBfzf --color=light,fg:232,bg:255,bg+:116,info:27\fR112.RE113114.RS115.B BASE SCHEME:116 (default: dark on 256-color terminal, otherwise 16)117118 \fBdark \fRColor scheme for dark 256-color terminal119 \fBlight \fRColor scheme for light 256-color terminal120 \fB16 \fRColor scheme for 16-color terminal121 \fBbw \fRNo colors122123.B COLOR:124 \fBfg \fRText125 \fBbg \fRBackground126 \fBhl \fRHighlighted substrings127 \fBfg+ \fRText (current line)128 \fBbg+ \fRBackground (current line)129 \fBhl+ \fRHighlighted substrings (current line)130 \fBinfo \fRInfo131 \fBprompt \fRPrompt132 \fBpointer \fRPointer to the current line133 \fBmarker \fRMulti-select marker134 \fBspinner \fRStreaming input indicator135 \fBheader \fRHeader136.RE104.BI "--bind=" "KEYBINDS"105Comma-separated list of custom key bindings. See \fBKEY BINDINGS\fR for the106details.107.TP138.B "--black"139Use black background108.B "--cycle"109Enable cyclic scroll110.TP111.B "--no-hscroll"112Disable horizontal scroll113.TP114.BI "--hscroll-off=" "COL"115Number of screen columns to keep to the right of the highlighted substring116(default: 10). Setting it to a large value will cause the text to be positioned117on the center of the screen.118.TP119.BI "--jump-labels=" "CHARS"120Label characters for \fBjump\fR and \fBjump-accept\fR121.SS Layout122.TP123.B "--reverse"124Reverse orientation125.TP126.BI "--margin=" MARGIN
20 unmodified lines
147e.g. \fBfzf --margin 10%\fR148 \fBfzf --margin 1,5%\fR149.RE150.TP169.BI "--tabstop=" SPACES170Number of spaces for a tab character (default: 8)171.TP172.B "--cycle"173Enable cyclic scroll174.TP175.B "--no-hscroll"176Disable horizontal scroll177.TP178.BI "--hscroll-off=" "COL"179Number of screen columns to keep to the right of the highlighted substring180(default: 10). Setting it to a large value will cause the text to be positioned181on the center of the screen.182.TP151.B "--inline-info"152Display finder info inline with the query153.TP186.BI "--jump-labels=" "CHARS"187Label characters for \fBjump\fR and \fBjump-accept\fR188.TP154.BI "--prompt=" "STR"155Input prompt (default: '> ')156.TP192.BI "--toggle-sort=" "KEY"193Key to toggle sort. For the list of the allowed key names, see \fB--bind\fR.157.BI "--header=" "STR"158The given string will be printed as the sticky header. The lines are displayed159in the given order from top to bottom regardless of \fB--reverse\fR option, and160are not affected by \fB--with-nth\fR. ANSI color codes are processed even when161\fB--ansi\fR is not set.162.TP195.BI "--bind=" "KEYBINDS"196Comma-separated list of custom key bindings. Each key binding expression197follows the following format: \fBKEY:ACTION\fR198.RS199e.g. \fBfzf --bind=ctrl-j:accept,ctrl-k:kill-line\fR200.RE163.BI "--header-lines=" "N"164The first N lines of the input are treated as the sticky header. When165\fB--with-nth\fR is set, the lines are transformed just like the other166lines that follow.167.SS Display168.TP169.B "--ansi"170Enable processing of ANSI color codes171.TP172.BI "--tabstop=" SPACES173Number of spaces for a tab character (default: 8)174.TP175.BI "--color=" "[BASE_SCHEME][,COLOR:ANSI]"176Color configuration. The name of the base color scheme is followed by custom177color mappings. Ansi color code of -1 denotes terminal default178foreground/background color.179180.RS203.B AVAILABLE KEYS: (SYNONYMS)204 \fIctrl-[a-z]\fR205 \fIalt-[a-z]\fR206 \fIf[1-10]\fR207 \fIenter\fR (\fIreturn\fR \fIctrl-m\fR)208 \fIspace\fR209 \fIbspace\fR (\fIbs\fR)210 \fIalt-enter\fR211 \fIalt-space\fR212 \fIalt-bspace\fR (\fIalt-bs\fR)213 \fIalt-/\fR214 \fItab\fR215 \fIbtab\fR (\fIshift-tab\fR)216 \fIesc\fR217 \fIdel\fR218 \fIup\fR219 \fIdown\fR220 \fIleft\fR221 \fIright\fR222 \fIhome\fR223 \fIend\fR224 \fIpgup\fR (\fIpage-up\fR)225 \fIpgdn\fR (\fIpage-down\fR)226 \fIshift-left\fR227 \fIshift-right\fR228 \fIdouble-click\fR229 or any single character181e.g. \fBfzf --color=bg+:24\fR182 \fBfzf --color=light,fg:232,bg:255,bg+:116,info:27\fR183.RE184185.RS233 \fBACTION: DEFAULT BINDINGS (NOTES):234 \fBabort\fR \fIctrl-c ctrl-g ctrl-q esc\fR235 \fBaccept\fR \fIenter double-click\fR236 \fBbackward-char\fR \fIctrl-b left\fR237 \fBbackward-delete-char\fR \fIctrl-h bspace\fR238 \fBbackward-kill-word\fR \fIalt-bs\fR239 \fBbackward-word\fR \fIalt-b shift-left\fR240 \fBbeginning-of-line\fR \fIctrl-a home\fR241 \fBcancel\fR242 \fBclear-screen\fR \fIctrl-l\fR243 \fBdelete-char\fR \fIdel\fR244 \fBdelete-char/eof\fR \fIctrl-d\fR245 \fBdeselect-all\fR246 \fBdown\fR \fIctrl-j ctrl-n down\fR247 \fBend-of-line\fR \fIctrl-e end\fR248 \fBexecute(...)\fR (see below for the details)249 \fBexecute-multi(...)\fR (see below for the details)250 \fBforward-char\fR \fIctrl-f right\fR251 \fBforward-word\fR \fIalt-f shift-right\fR252 \fBignore\fR253 \fBjump\fR (EasyMotion-like 2-keystroke movement)254 \fBjump-accept\fR (jump and accept)255 \fBkill-line\fR256 \fBkill-word\fR \fIalt-d\fR257 \fBnext-history\fR (\fIctrl-n\fR on \fB--history\fR)258 \fBpage-down\fR \fIpgdn\fR259 \fBpage-up\fR \fIpgup\fR260 \fBprevious-history\fR (\fIctrl-p\fR on \fB--history\fR)261 \fBprint-query\fR (print query and exit)262 \fBselect-all\fR263 \fBtoggle\fR264 \fBtoggle-all\fR265 \fBtoggle-down\fR \fIctrl-i (tab)\fR266 \fBtoggle-in\fR (\fB--reverse\fR ? \fBtoggle-up\fR : \fBtoggle-down\fR)267 \fBtoggle-out\fR (\fB--reverse\fR ? \fBtoggle-down\fR : \fBtoggle-up\fR)268 \fBtoggle-sort\fR (equivalent to \fB--toggle-sort\fR)269 \fBtoggle-up\fR \fIbtab (shift-tab)\fR270 \fBunix-line-discard\fR \fIctrl-u\fR271 \fBunix-word-rubout\fR \fIctrl-w\fR272 \fBup\fR \fIctrl-k ctrl-p up\fR273 \fByank\fR \fIctrl-y\fR274.RE186.B BASE SCHEME:187 (default: dark on 256-color terminal, otherwise 16)188276.RS277With \fBexecute(...)\fR action, you can execute arbitrary commands without278leaving fzf. For example, you can turn fzf into a simple file browser by279binding \fBenter\fR key to \fBless\fR command like follows.189 \fBdark \fRColor scheme for dark 256-color terminal190 \fBlight \fRColor scheme for light 256-color terminal191 \fB16 \fRColor scheme for 16-color terminal192 \fBbw \fRNo colors193281.RS282\fBfzf --bind "enter:execute(less {})"\fR194.B COLOR:195 \fBfg \fRText196 \fBbg \fRBackground197 \fBhl \fRHighlighted substrings198 \fBfg+ \fRText (current line)199 \fBbg+ \fRBackground (current line)200 \fBhl+ \fRHighlighted substrings (current line)201 \fBinfo \fRInfo202 \fBprompt \fRPrompt203 \fBpointer \fRPointer to the current line204 \fBmarker \fRMulti-select marker205 \fBspinner \fRStreaming input indicator206 \fBheader \fRHeader207.RE284285\fB{}\fR is the placeholder for the double-quoted string of the current line.286If the command contains parentheses, you can use any of the following287alternative notations to avoid parse errors.288289 \fBexecute[...]\fR290 \fBexecute~...~\fR291 \fBexecute!...!\fR292 \fBexecute@...@\fR293 \fBexecute#...#\fR294 \fBexecute$...$\fR295 \fBexecute%...%\fR296 \fBexecute^...^\fR297 \fBexecute&...&\fR298 \fBexecute*...*\fR299 \fBexecute;...;\fR300 \fBexecute/.../\fR301 \fBexecute|...|\fR302 \fBexecute:...\fR303.RS304This is the special form that frees you from parse errors as it does not expect305the closing character. The catch is that it should be the last one in the306comma-separated list.307.RE308309\fBexecute-multi(...)\fR is an alternative action that executes the command310with the selected entries when multi-select is enabled (\fB--multi\fR). With311this action, \fB{}\fR is replaced with the double-quoted strings of the312selected entries separated by spaces.313314.RE208.TP209.B "--black"210Use black background211.SS History212.TP213.BI "--history=" "HISTORY_FILE"214Load search history from the specified file and update the file on completion.215When enabled, \fBCTRL-N\fR and \fBCTRL-P\fR are automatically remapped to216\fBnext-history\fR and \fBprevious-history\fR.217.TP218.BI "--history-size=" "N"219Maximum number of entries in the history file (default: 1000). The file is220automatically truncated when the number of the lines exceeds the value.221.SS Preview222.TP325.BI "--header=" "STR"326The given string will be printed as the sticky header. The lines are displayed327in the given order from top to bottom regardless of \fB--reverse\fR option, and328are not affected by \fB--with-nth\fR. ANSI color codes are processed even when329\fB--ansi\fR is not set.223.BI "--preview=" "COMMAND"224Execute the given command for the current line and display the result on the225preview window. \fB{}\fR is the placeholder for the quoted string of the226current line.227228.RS229e.g. \fBfzf --preview="head -$LINES {}"\fR230.RE231.TP331.BI "--header-lines=" "N"332The first N lines of the input are treated as the sticky header. When333\fB--with-nth\fR is set, the lines are transformed just like the other334lines that follow.232.BI "--preview-window=" "[POSITION][:SIZE[%]][:hidden]"233Determine the layout of the preview window. If the argument ends with234\fB:hidden\fR, the preview window will be hidden by default until235\fBtoggle-preview\fR action is triggered.236237.RS238.B POSITION: (default: right)239 \fBup240 \fBdown241 \fBleft242 \fBright243.RE244245.RS246e.g. \fBfzf --preview="head {}" --preview-window=up:30%\fR247 \fBfzf --preview="file {}" --preview-window=down:1\fR248.RE249.SS Scripting250.TP251.BI "-q, --query=" "STR"252Start the finder with the given query
16 unmodified lines
269the default enter key. When this option is set, fzf will print the name of the270key pressed as the first line of its output (or as the second line if271\fB--print-query\fR is also used). The line will be empty if fzf is completed272with the default enter key.273274.RS275e.g. \fBfzf --expect=ctrl-v,ctrl-t,alt-s,f1,f2,~,@\fR276.RE277.TP278.B "--sync"279Synchronous search for multi-staged filtering. If specified, fzf will launch280ncurses finder only after the input stream is complete.281282.RS283e.g. \fBfzf --multi | fzf --sync\fR284.RE285370.SH ENVIRONMENT286.SH ENVIRONMENT VARIABLES287.TP288.B FZF_DEFAULT_COMMAND289Default command to use when input is tty290.TP
45 unmodified lines
336occurrences of the string.337338.SS Anchored-match339A term can be prefixed by \fB^\fR, or suffixed by \fB$\fR to become an424anchored-match term. Then fzf will search for the items that start with or end340anchored-match term. Then fzf will search for the lines that start with or end341with the given string. An anchored-match term is also an exact-match term.342343.SS Negation428If a term is prefixed by \fB!\fR, fzf will exclude the items that satisfy the344If a term is prefixed by \fB!\fR, fzf will exclude the lines that satisfy the345term from the result.346347.SS Exact-match by default348If you don't prefer fuzzy matching and do not wish to "quote" (prefixing with
6 unmodified lines
355\fBrb\fR, or \fBpy\fR.356357e.g. \fB^core go$ | rb$ | py$\fR358359.SH KEY BINDINGS360You can customize key bindings of fzf with \fB--bind\fR option which takes361a comma-separated list of key binding expressions. Each key binding expression362follows the following format: \fBKEY:ACTION\fR363364e.g. \fBfzf --bind=ctrl-j:accept,ctrl-k:kill-line\fR365366.B AVAILABLE KEYS: (SYNONYMS)367 \fIctrl-[a-z]\fR368 \fIalt-[a-z]\fR369 \fIf[1-10]\fR370 \fIenter\fR (\fIreturn\fR \fIctrl-m\fR)371 \fIspace\fR372 \fIbspace\fR (\fIbs\fR)373 \fIalt-enter\fR374 \fIalt-space\fR375 \fIalt-bspace\fR (\fIalt-bs\fR)376 \fIalt-/\fR377 \fItab\fR378 \fIbtab\fR (\fIshift-tab\fR)379 \fIesc\fR380 \fIdel\fR381 \fIup\fR382 \fIdown\fR383 \fIleft\fR384 \fIright\fR385 \fIhome\fR386 \fIend\fR387 \fIpgup\fR (\fIpage-up\fR)388 \fIpgdn\fR (\fIpage-down\fR)389 \fIshift-left\fR390 \fIshift-right\fR391 \fIdouble-click\fR392 or any single character393394 \fBACTION: DEFAULT BINDINGS (NOTES):395 \fBabort\fR \fIctrl-c ctrl-g ctrl-q esc\fR396 \fBaccept\fR \fIenter double-click\fR397 \fBbackward-char\fR \fIctrl-b left\fR398 \fBbackward-delete-char\fR \fIctrl-h bspace\fR399 \fBbackward-kill-word\fR \fIalt-bs\fR400 \fBbackward-word\fR \fIalt-b shift-left\fR401 \fBbeginning-of-line\fR \fIctrl-a home\fR402 \fBcancel\fR403 \fBclear-screen\fR \fIctrl-l\fR404 \fBdelete-char\fR \fIdel\fR405 \fBdelete-char/eof\fR \fIctrl-d\fR406 \fBdeselect-all\fR407 \fBdown\fR \fIctrl-j ctrl-n down\fR408 \fBend-of-line\fR \fIctrl-e end\fR409 \fBexecute(...)\fR (see below for the details)410 \fBexecute-multi(...)\fR (see below for the details)411 \fBforward-char\fR \fIctrl-f right\fR412 \fBforward-word\fR \fIalt-f shift-right\fR413 \fBignore\fR414 \fBjump\fR (EasyMotion-like 2-keystroke movement)415 \fBjump-accept\fR (jump and accept)416 \fBkill-line\fR417 \fBkill-word\fR \fIalt-d\fR418 \fBnext-history\fR (\fIctrl-n\fR on \fB--history\fR)419 \fBpage-down\fR \fIpgdn\fR420 \fBpage-up\fR \fIpgup\fR421 \fBprevious-history\fR (\fIctrl-p\fR on \fB--history\fR)422 \fBprint-query\fR (print query and exit)423 \fBselect-all\fR424 \fBtoggle\fR425 \fBtoggle-all\fR426 \fBtoggle-down\fR \fIctrl-i (tab)\fR427 \fBtoggle-in\fR (\fB--reverse\fR ? \fBtoggle-up\fR : \fBtoggle-down\fR)428 \fBtoggle-out\fR (\fB--reverse\fR ? \fBtoggle-down\fR : \fBtoggle-up\fR)429 \fBtoggle-preview\fR430 \fBtoggle-sort\fR (equivalent to \fB--toggle-sort\fR)431 \fBtoggle-up\fR \fIbtab (shift-tab)\fR432 \fBunix-line-discard\fR \fIctrl-u\fR433 \fBunix-word-rubout\fR \fIctrl-w\fR434 \fBup\fR \fIctrl-k ctrl-p up\fR435 \fByank\fR \fIctrl-y\fR436437With \fBexecute(...)\fR action, you can execute arbitrary commands without438leaving fzf. For example, you can turn fzf into a simple file browser by439binding \fBenter\fR key to \fBless\fR command like follows.440441 \fBfzf --bind "enter:execute(less {})"\fR442443\fB{}\fR is the placeholder for the quoted string of the current line.444If the command contains parentheses, you can use any of the following445alternative notations to avoid parse errors.446447 \fBexecute[...]\fR448 \fBexecute~...~\fR449 \fBexecute!...!\fR450 \fBexecute@...@\fR451 \fBexecute#...#\fR452 \fBexecute$...$\fR453 \fBexecute%...%\fR454 \fBexecute^...^\fR455 \fBexecute&...&\fR456 \fBexecute*...*\fR457 \fBexecute;...;\fR458 \fBexecute/.../\fR459 \fBexecute|...|\fR460 \fBexecute:...\fR461.RS462This is the special form that frees you from parse errors as it does not expect463the closing character. The catch is that it should be the last one in the464comma-separated list.465.RE466467\fBexecute-multi(...)\fR is an alternative action that executes the command468with the selected entries when multi-select is enabled (\fB--multi\fR). With469this action, \fB{}\fR is replaced with the quoted strings of the selected470entries separated by spaces.471472.SH AUTHOR473Junegunn Choi (\fIjunegunn.c@gmail.com\fR)474475.SH SEE ALSO
14 unmodified lines
modified:src/constants.go+1 added-1 removed
6 unmodified lines
7)89const (10 // Current version11 version = "0.12.2"11 version = "0.13.0"1213 // Core14 coordinatorDelayMax time.Duration = 100 * time.Millisecond15 coordinatorDelayStep time.Duration = 10 * time.Millisecond
45 unmodified lines
modified:CHANGELOG.md+7 added-3 removed
1CHANGELOG2=========340.12.340.13.05------6- `{}` in execute action is replaced to the single-quoted string of the7 current line6- Added preview feature7 - `--preview CMD`8 - `--preview-window POS[:SIZE][:hidden]`9- `{}` in execute action is now replaced to the single-quoted (instead of10 double-quoted) string of the current line11- Fixed to ignore control characters for bracketed paste mode12130.12.214------15
399 unmodified lines
modified:install+2 added-2 removed
1#!/usr/bin/env bash23set -u45[[ "$@" =~ --pre ]] && version=0.12.2 pre=1 ||6 version=0.12.2 pre=05[[ "$@" =~ --pre ]] && version=0.13.0 pre=1 ||6 version=0.13.0 pre=078auto_completion=9key_bindings=10update_config=2
387 unmodified lines