Skip to content

Integrate rga-fzf function into a script #174

Closed Answered by amigthea
amigthea asked this question in Q&A
Discussion options

You must be logged in to vote

I came up with a working solution:

fzf_explorer() {
  # Store the STDOUT of fzf in a variable
  selection=$(find -type d | fzf-tmux -p95%,100% --ansi --multi \
  --preview='tree -C {}' --preview-window='right,50%,border-left' \
  --prompt='Dirs > ' \
  --delimiter : \
  --bind='del:execute(rm -ri {+})' \
  --bind='ctrl-p:toggle-preview' \
  --bind='ctrl-d:change-prompt(Dirs > )' \
  --bind='ctrl-d:+reload(find -type d)' \
  --bind='ctrl-d:+change-preview(tree -C {})' \
  --bind='ctrl-d:+change-preview-window(right,50%,border-left)' \
  --bind='ctrl-d:+refresh-preview' \
  --bind='ctrl-f:change-prompt(Files > )' \
  --bind='ctrl-f:+reload(find -type f)' \
  --bind='ctrl-f:+change-preview(b…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by amigthea
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant
Converted from issue

This discussion was converted from issue #173 on June 26, 2023 12:41.