Replies: 1 comment
-
hey i recall seeing this in a blog just found it again but $ echo '' | fzf --print-query --preview 'echo "a\nb\nc\nd" | awk {q}' https://github.com/pawelduda/fzf-live-repl Also Regex is possible i haven't developed it past concept but the plan was to take whatever successful matching regex pattern i made saving it and for a proper filter later in the script. (also this was based off someone elese's work just cant remember where i picked it up) declare gvar=''
declare Fvar=''
if [[ -z "$1" ]]; then
Fvar='.'; else
Fvar="$1"
fi
if [[ -z "$2" ]]; then
gvar='.'; else
gvar="$2"
fi
grep_flag_available="rg '{q}' ./ --color=always --colors=match:fg:12 --no-filename"
fd -uu -t f "$Fvar" | rg "$gvar" --no-filename | fzf --phony \
--preview="nvimpager -c {} | $grep_flag_available"
unset gvar
unset Fvar |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
replace-query
#2465todo #395
todo #2643
todo #2531
Beta Was this translation helpful? Give feedback.
All reactions