summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJunegunn Choi <junegunn.c@gmail.com>2024-06-06 15:15:15 +0900
committerJunegunn Choi <junegunn.c@gmail.com>2024-06-06 17:40:15 +0900
commitb1460d4787adb84b54262ff69caf6ad3dfac1e8a (patch)
tree5d8ce48f2a87db3f04c183fe63f8f1e2aa6afae7
parent7dc9e1487434e6488d220cb07a8c5a4da3e8efb8 (diff)
hasPreviewFlags should ignore escaped placeholder
This reload command wouldn't run before the fix: : | fzf --bind 'start:reload:echo \{}'
-rw-r--r--src/terminal.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/terminal.go b/src/terminal.go
index 7846e662..386e0850 100644
--- a/src/terminal.go
+++ b/src/terminal.go
@@ -2762,7 +2762,10 @@ func parsePlaceholder(match string) (bool, string, placeholderFlags) {
func hasPreviewFlags(template string) (slot bool, plus bool, forceUpdate bool) {
for _, match := range placeholder.FindAllString(template, -1) {
- _, _, flags := parsePlaceholder(match)
+ escaped, _, flags := parsePlaceholder(match)
+ if escaped {
+ continue
+ }
if flags.plus {
plus = true
}