Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fish ctrl-t doesn't respect the relative directory with user defined $FZF_CTRL_T_COMMAND #3705

Closed
4 of 9 tasks
kpskp77 opened this issue Mar 31, 2024 · 2 comments
Closed
4 of 9 tasks
Labels

Comments

@kpskp77
Copy link

kpskp77 commented Mar 31, 2024

Checklist

  • I have read through the manual page (man fzf)
  • I have searched through the existing issues

Output of fzf --version

0.48 (devel)

OS

  • Linux
  • macOS
  • Windows
  • Etc.

Shell

  • bash
  • zsh
  • fish

Problem / Steps to reproduce

> echo $FZF_CTRL_T_COMMAND
fd --follow --exclude tags --exclude .svn --exclude .git . $dir 2>/dev/null

I think the problem is the variable $dir is not exported in key-bindings.fish

function fzf_key_bindings

  # Store current token in $dir as root for the 'find' command
  function fzf-file-widget -d "List files and folders"
    set -l commandline (__fzf_parse_commandline)
    set -l dir $commandline[1] ## <--- should be `set -lx` here?
    set -l fzf_query $commandline[2]
    set -l prefix $commandline[3]
@junegunn
Copy link
Owner

junegunn commented Mar 31, 2024

Maybe you're running into #3684?

@junegunn
Copy link
Owner

Thanks for the report, your analysis is spot on. It should be fixed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants