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

[Bug]: Telescope File Finder doesn't Ignore .gitignore #2028

Closed
3 tasks done
christopher-besch opened this issue Dec 4, 2021 · 10 comments · May be fixed by LunarVim/lunarvim.org#144
Closed
3 tasks done

[Bug]: Telescope File Finder doesn't Ignore .gitignore #2028

christopher-besch opened this issue Dec 4, 2021 · 10 comments · May be fixed by LunarVim/lunarvim.org#144
Labels
invalid This doesn't seem right

Comments

@christopher-besch
Copy link

christopher-besch commented Dec 4, 2021

Problem description

In a version of LunarVim from over a month ago the Telescope file finder ignored anything matched by the local .gitignore. In the latest release this isn't the case anymore and searching with it results in a lot of clutter.
When I'm looking for one of my code files I don't care about those bazillion node_module files.

LunarVim version

0.6.1
As of the creation of this Issue, the latest rolling version shows the same problem.

Neovim version (>= 0.5)

v0.7.0-dev+667-g419e0d117

Screenshots

image
I'm looking for my index.tsx file but instead I get a lot of garbage from the node_modules directory.

I have

  • Read the readme
  • Read the wiki
  • Searched for similar issues
@christopher-besch christopher-besch added the bug Something isn't working label Dec 4, 2021
@chase
Copy link
Collaborator

chase commented Dec 4, 2021

If you do a fd index in the same directory does it produce the same output?

We haven't changed the settings and Telescope's version is pinned, so I'm not sure this is on our side of things. Can you post your config.lua?

@christopher-besch
Copy link
Author

christopher-besch commented Dec 4, 2021

Solved it; I didn't have fd installed as I moved from Fedora to Manjaro. I didn't know it was a dependency of LunarVim. Maybe this should be noted in the documentation.

Thanks a lot for your help, @chase!

@chase chase added invalid This doesn't seem right and removed bug Something isn't working labels Dec 4, 2021
@chase chase closed this as completed Dec 4, 2021
@christopher-besch
Copy link
Author

I've opened a PR, which is also adding xclip.

@kylo252
Copy link
Collaborator

kylo252 commented Dec 4, 2021

Solved it; I didn't have fd installed as I moved from Fedora to Manjaro. I didn't know it was a dependency of LunarVim. Maybe this should be noted in the documentation.

It does show up in :checkhealth as well.

@kylo252
Copy link
Collaborator

kylo252 commented Dec 4, 2021

The weird part is that ripgrep should've been the next in line if fd was not found, and it should've ignored those unless you have modified its config somehow.

@christopher-besch
Copy link
Author

ripgrep should've been the next in line

I mean the file search still worked, it just didn't ignore using the .gitignore. Maybe ripgrep just doesn't care about the .gitignore.

@kylo252
Copy link
Collaborator

kylo252 commented Dec 4, 2021

It does care unless you specified otherwise.

@christopher-besch
Copy link
Author

christopher-besch commented Dec 4, 2021

It does care unless you specified otherwise.

Weird, even with the default config it didn't work and I'm pretty sure I didn't explicitly tell it not to...

@kylo252
Copy link
Collaborator

kylo252 commented Dec 4, 2021

Weird, even with the default config it didn't work and I'm pretty sure I didn't explicitly tell it not to...

It could be that it was invoked from a different directory then.


Tip: you can add global ignore settings for fd in ~/.config/fd/ignore and for rg in ~/.config/ripgrep/ripgreprc.

@christopher-besch
Copy link
Author

image
mh...
I didn't touch these.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants