diff options
author | Junegunn Choi <junegunn.c@gmail.com> | 2022-08-02 13:44:55 +0900 |
---|---|---|
committer | Junegunn Choi <junegunn.c@gmail.com> | 2022-08-02 21:48:19 +0900 |
commit | f0bfeba733f755a81b2e2d327268f2dabae8f684 (patch) | |
tree | f772989dd01c4f7cb7f69937932c0ded5d4b0ece /man/man1/fzf-tmux.1 | |
parent | c3a7a24eeaa5b7451e652df68683b5e8b24cde6b (diff) |
Add new tiebreak: 'chunk'
Favors the line with shorter matched chunk. A chunk is a set of
consecutive non-whitespace characters.
Unlike the default `length`, this new scheme works well with tabular input.
# length prefers item #1, because the whole line is shorter,
# chunk prefers item #2, because the matched chunk ("foo") is shorter
fzf --height=6 --header-lines=2 --tiebreak=chunk --reverse --query=fo << "EOF"
N | Field1 | Field2 | Field3
- | ------ | ------ | ------
1 | hello | foobar | baz
2 | world | foo | bazbaz
EOF
If the input does not contain any spaces, `chunk` is equivalent to
`length`. But we're not going to set it as the default because it is
computationally more expensive.
Close #2285
Close #2537
- Not the exact solution to --tiebreak=length not taking --nth into account,
but this should work. And the added benefit is that it works well even
when --nth is not provided.
- Adding a bonus point to the last character of a word didn't turn out great.
The order of the result suddenly changes when you type in the last
character in the word producing a jarring effect.
Diffstat (limited to 'man/man1/fzf-tmux.1')
-rw-r--r-- | man/man1/fzf-tmux.1 | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/man/man1/fzf-tmux.1 b/man/man1/fzf-tmux.1 index ea5591f5..8f86c743 100644 --- a/man/man1/fzf-tmux.1 +++ b/man/man1/fzf-tmux.1 @@ -21,7 +21,7 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. .. -.TH fzf-tmux 1 "Jul 2022" "fzf 0.31.0" "fzf-tmux - open fzf in tmux split pane" +.TH fzf-tmux 1 "Aug 2022" "fzf 0.32.0" "fzf-tmux - open fzf in tmux split pane" .SH NAME fzf-tmux - open fzf in tmux split pane |