Junegunn Choi
15d6c17390
Fix ANSI attributes lost when nth:regular is set
...
Example:
# foo was not displayed in italic
echo -e "\x1b[33;3mfoo \x1b[mbar" | fzf --ansi --color fg:dim,nth:regular --nth 1
2025-05-30 21:02:35 +09:00
Junegunn Choi
a9d1d42436
Fix ANSI attributes lost when 'regular' attribute is set to fg or nth
...
Examples:
echo -e "\x1b[33;3mfoo \x1b[mbar" | fzf --ansi --color fg:regular
echo -e "\x1b[33;3mfoo \x1b[mbar" | fzf --ansi --color nth:regular
2025-05-30 20:43:20 +09:00
Junegunn Choi
54fd92b7dd
--no-color: Keep ANSI attributes in the list
...
Example:
echo -e "\x1b[33;3mfoo \x1b[34;4mbar\x1b[m baz" | fzf --ansi --no-color
2025-05-30 20:33:21 +09:00
Junegunn Choi
835906d392
--no-color: Keep ANSI attributes in preview window
...
Example:
fzf --preview 'echo -e "\x1b[33;3mfoo \x1b[34;4mbar\x1b[m baz"' --no-color
2025-05-30 20:26:53 +09:00
Junegunn Choi
1721e6a1ed
Do not apply 'nth' attributes to trailing whitespaces
...
# foo bar
# ----- <- previously underlined trailing whitespace
# --- <- with the fix, trailing whitespace is excluded
fzf --color nth:underline --nth 1 <<< 'foo bar'
2025-05-30 19:43:10 +09:00
Junegunn Choi
c7ee3b833f
Fix FZF_CLICK_HEADER_NTH for multi-line headers
2025-05-30 17:10:26 +09:00
Junegunn Choi
ffb6e28ca7
Allow customizing --ghost color via '--color ghost'
...
Examples:
# Dimmed red
fzf --ghost booya --color ghost:red
# Regular red
fzf --ghost booya --color ghost:red:regular
Close #4398
2025-05-28 00:27:33 +09:00
Junegunn Choi
a4c6846851
Fix background color of 'disabled' query
...
fzf --color disabled:red,list-bg:blue --disabled --query foo --input-border
2025-05-28 00:17:41 +09:00
Junegunn Choi
b27943423e
Show ellipsis for truncated labels
...
Close #4390
2025-05-17 11:25:15 +09:00
Junegunn Choi
c6d83047e5
Allow whitespace as separator in --color option
2025-05-04 15:08:23 +09:00
Junegunn Choi
cd9517b679
Add 'alt-bg' color for striped lines ( #4370 )
...
Test cases:
1. 'jump' should show alternating background colors even when 'alt-bg' is
not defined as before.
go run main.go --bind load:jump
Two differences:
* The alternating lines will not be in bold (was a bug)
* The marker column will not be rendered with alternating background color
2. Use alternating background color when 'alt-bg' is set
go run main.go --color bg:238,alt-bg:237
go run main.go --color bg:238,alt-bg:237 --highlight-line
3. 'selected-bg' should take precedence
go run main.go --color bg:238,alt-bg:237,selected-bg:232 \
--highlight-line --multi --bind 'load:select+up+select+up'
4. Should work with text with ANSI colors
declare -f | perl -0777 -pe 's/^}\n/}\0/gm' |
bat --plain --language bash --color always |
go run main.go --read0 --ansi --reverse --multi \
--color bg:237,alt-bg:238,current-bg:236 --highlight-line
---
Close #4354
Fix #4372
2025-05-04 14:32:06 +09:00
Junegunn Choi
d2c662e54f
Reset coordinator delay on 'reload'
...
Fix #4364
2025-04-25 21:30:25 +09:00
RafaelDominiquini
06ae9b0f3b
Add missing environment variables ( #4356 )
...
Co-authored-by: Rafael Baboni Dominiquini <rafaeldominiquini@gmail.com >
Co-authored-by: Junegunn Choi <junegunn.c@gmail.com >
2025-04-22 20:51:43 +09:00
Junegunn Choi
2a9c1c06a4
Revert "Disable tmux popup when already running inside one ( #4351 )"
...
This reverts commit af8fe918d8 .
Fix #4360
Fix #4359
2025-04-22 20:20:21 +09:00
Junegunn Choi
1d761684c5
Add --tty-default=/dev/tty and --no-tty-default option ( #4352 )
...
Fix #4242 .
Use --no-tty-default, if you want fzf to perform a TTY look-up instead of defaulting to /dev/tty.
2025-04-20 11:24:50 +09:00
Pierre Guinoiseau
af8fe918d8
Disable tmux popup when already running inside one ( #4351 )
2025-04-18 17:35:48 +09:00
phanium
66df24040f
Fix panic when use header border without pointer/marker ( #4345 )
2025-04-13 20:24:29 +09:00
Junegunn Choi
0edb5d5ebb
Fix trailing ␊ not rendered with '--read0 --no-multi-line'
...
https://github.com/junegunn/fzf/pull/4334#issue-2966013714
# Should display foo␊
echo -en "foo\n" | fzf --read0 --no-multi-line
2025-04-11 20:46:49 +09:00
Junegunn Choi
9ffc2c7ca3
reader: Do not append '/' to '/'
...
https://github.com/junegunn/fzf/pull/4334#issue-2966013714
2025-04-11 20:38:16 +09:00
Junegunn Choi
93cb3758b5
0.61.1
2025-04-06 13:09:59 +09:00
Junegunn Choi
d22e75dcdd
Disable bracketed paste mode on exit
...
Related: #4338
2025-04-06 12:51:36 +09:00
Junegunn Choi
31fd207ba2
Add 'r' flag (raw) for unquoted output
...
By default, placeholder expressions are automatically quoted to ensure
they are safely passed as arguments to external programs.
The r flag ({r}, {r1}, etc.) disables this behavior, outputting the
evaluated value without quotes.
For example,
echo 'foo bar' | fzf --preview 'echo {} {r}'
The preview command becomes:
echo 'foo bar' foo bar
Since `{r}` expands to unquoted "foo bar", 'foo' and 'bar' are passed
as separate arguments.
**Use with caution** Unquoted output can lead to broken commands.
echo "let's go" | fzf --preview 'echo {r}'
Close #4330
2025-03-30 19:49:05 +09:00
Junegunn Choi
ba6d1b8772
Add change-ghost and transform-ghost
2025-03-28 23:35:20 +09:00
Junegunn Choi
0dce561ec9
Fix header window not updated on change-header
2025-03-28 23:23:43 +09:00
Junegunn Choi
664ee1f483
Add change-pointer and transform-pointer
...
Close #4178
2025-03-28 21:28:25 +09:00
Junegunn Choi
dac5b6fde1
Fix info not updated after track-current is disabled due to race condition
2025-03-26 16:00:05 +09:00
Junegunn Choi
998c57442b
Fix query precedence in an action chain ( #4326 )
...
When 'search' and any action that modifies the query are in an action
chain, anything that comes later takes precedence.
2025-03-26 15:47:43 +09:00
Junegunn Choi
4a0ab6c926
Improve query modification prevention in input-less mode
...
fzf would restore the original query in input-less mode after executing
a chain of actions.
This commit changes the behavior so that the restoration
happens after each action to allow something like
'show-input+change-query(...)+hide-input'.
Fix #4326
2025-03-26 10:34:52 +09:00
Junegunn Choi
f43e82f17f
Do not ignore current query when input is hidden
...
* The initial query given by --query should be respected
* The current query should still be respected after `hide-input`
(or `toggle-input)
Fix #4327
2025-03-25 21:08:06 +09:00
Junegunn Choi
62238620a5
Fix first entry not clickable when input section is hidden
...
Fix #4325
2025-03-24 22:08:57 +09:00
Junegunn Choi
200745011a
Fix cursor position when prompt is truncated
...
e.g.
fzf --preview 'cat {}' --prompt "$(seq 100 | xargs)"
fzf --preview 'cat {}' --prompt "$(seq 100 | xargs)" --input-border
2025-03-24 17:09:44 +09:00
Junegunn Choi
82fd88339b
Fix offset-middle not updating the list
2025-03-23 11:13:21 +09:00
Junegunn Choi
29cf28d845
Suppress 'change' event during bracketed paste mode
...
Close #4316
2025-03-22 09:17:18 +09:00
Junegunn Choi
7e4dbb5f3b
Prevent start:track-current from being disabled
...
# track-current state can be immediately disabled
fzf --sync --bind 'start:track-current'
2025-03-20 11:51:20 +09:00
Junegunn Choi
f92f9f137a
Fix wrapping of the list section
...
# The first line of the second chunk would prematurely wrap
printf '%0500s\n\n%0500s' 0 0 | fzf --wrap --read0
2025-03-16 01:57:20 +09:00
Junegunn Choi
87f7f436e8
Fix ghost text with inline info
...
Fix #4312
2025-03-15 18:42:08 +09:00
Junegunn Choi
4298c0b1eb
Add --ghost=TEXT to display a ghost text when the input is empty
2025-03-14 16:46:23 +09:00
Gabriel Marin
6c104d771e
Change 'interface{}' to 'any' ( #4308 )
2025-03-11 14:24:54 +09:00
Junegunn Choi
aefb9a5bc4
Nullify unwanted FZF_DEFAULT_* variables in tmux popup
...
Fix #4298
2025-03-10 18:18:50 +09:00
Junegunn Choi
8916cbc6ab
[windows] Prevent fzf from consuming user input while paused
...
This partly fixes #4260 .
fzf still can consume the first key stroke.
2025-03-03 14:04:16 +09:00
Junegunn Choi
3ba82b6d87
Make truncateQuery faster
...
https://github.com/junegunn/fzf/issues/4292#issuecomment-2687051731
2025-02-27 15:49:15 +09:00
Junegunn Choi
4e5e925e39
Increase the query length limit from 300 to 1000
...
Close #4292
2025-02-27 11:43:58 +09:00
Junegunn Choi
b7248d4115
Remove temp files before 'become' when using --tmux option
...
Close #4283
But the temp files for the `f` flags in the 'become' template will not
be removed, because we will need them after "becoming" another program.
e.g. fzf --bind 'enter:become:cat {f}'
2025-02-26 20:47:09 +09:00
Junegunn Choi
639253840f
Trim trailing whitespaces after processing ANSI sequences
...
Close #4282
2025-02-26 16:17:12 +09:00
Junegunn Choi
710ebdf9c1
Make --accept-nth compatible with --select-1
...
Fix #4287
2025-02-26 00:25:23 +09:00
alex-huff
cd1da27ff2
Fix condition for using item numlines cache ( #4285 )
2025-02-25 20:25:26 +09:00
Junegunn Choi
c1accc2e5b
Use '/' as path separator on MSYS2
...
Fix #4281
2025-02-25 10:12:19 +09:00
Junegunn Choi
e4489dcbc1
Fix regression: Trim trailing whitespaces when using --with-nth
...
https://github.com/junegunn/fzf/issues/4272#issuecomment-2677279620
2025-02-24 18:40:13 +09:00
Junegunn Choi
461115afde
Add support for {n} in --with-nth and --accept-nth templates
...
Close #4275
2025-02-23 19:47:56 +09:00
Junegunn Choi
d79902ae59
Fix 'jump' when pointer is empty
...
Fix #4270
2025-02-22 19:05:30 +09:00