hasPreviewFlags should ignore escaped placeholder

This reload command wouldn't run before the fix:

  : | fzf --bind 'start:reload:echo \{}'
This commit is contained in:
Junegunn Choi 2024-06-06 15:15:15 +09:00
parent 7dc9e14874
commit b1460d4787
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

View File

@ -2762,7 +2762,10 @@ func parsePlaceholder(match string) (bool, string, placeholderFlags) {
func hasPreviewFlags(template string) (slot bool, plus bool, forceUpdate bool) { func hasPreviewFlags(template string) (slot bool, plus bool, forceUpdate bool) {
for _, match := range placeholder.FindAllString(template, -1) { for _, match := range placeholder.FindAllString(template, -1) {
_, _, flags := parsePlaceholder(match) escaped, _, flags := parsePlaceholder(match)
if escaped {
continue
}
if flags.plus { if flags.plus {
plus = true plus = true
} }