diff options
author | Junegunn Choi <junegunn.c@gmail.com> | 2017-12-01 03:27:58 +0900 |
---|---|---|
committer | Junegunn Choi <junegunn.c@gmail.com> | 2017-12-01 03:28:10 +0900 |
commit | f6b19620566a299d8813ee51e02c26d21525d339 (patch) | |
tree | 2a0b871930cefea7447e50cfb18dbc505a4ee4a9 /man | |
parent | b3b101a89cd4a9431d98293e63e349367e83ac65 (diff) |
Inject $LINES and $COLUMNS when running preview command
Close #1168
Diffstat (limited to 'man')
-rw-r--r-- | man/man1/fzf.1 | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/man/man1/fzf.1 b/man/man1/fzf.1 index aea5fea7..89d7f93f 100644 --- a/man/man1/fzf.1 +++ b/man/man1/fzf.1 @@ -272,14 +272,17 @@ string, specify field index expressions between the braces (See \fBFIELD INDEX EXPRESSION\fR for the details). .RS -e.g. \fBfzf --preview="head -$LINES {}"\fR +e.g. \fBfzf --preview='head -$LINES {}'\fR \fBls -l | fzf --preview="echo user={3} when={-4..-2}; cat {-1}" --header-lines=1\fR +fzf overrides \fB$LINES\fR and \fB$COLUMNS\fR so that they represent the exact +size of the preview window. + A placeholder expression starting with \fB+\fR flag will be replaced to the space-separated list of the selected lines (or the current line if no selection was made) individually quoted. -e.g. \fBfzf --multi --preview="head -10 {+}"\fR +e.g. \fBfzf --multi --preview='head -10 {+}'\fR \fBgit log --oneline | fzf --multi --preview 'git show {+1}'\fR Also, \fB{q}\fR is replaced to the current query string. |