-
-
Notifications
You must be signed in to change notification settings - Fork 202
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
Use gitignore when finding project files #1777
Conversation
wait! Now this command will list all files including all How are they ignored? Automatically by a call to the For a full Lisp solution, very welcome, we should ignore node_modules too :S What other big repositories should we ignore? |
(defun list-project-files-git (directory) | ||
"List all files in a git project using git ls-files." | ||
(handler-case | ||
(let ((cmd "git ls-files --cached --others --exclude-standard")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this command should be tweakable -> global parameter.
What do you mean? Won't they be ignored by
Hahh I had no idea it tried using Thanks! 😄 |
I'm sorry, I'm adding a section in the Install doc to mention it earlier. But wait! again, because if |
You're good, I'm the one that missed it 😆
Yeah, if |
This PR takes into account .gitignore when finding project files in git repos by default. Toggle with
*respect-gitignore*
.Besides having more accurate autocomplete (e.g. ignoring .git/node_modules),
project-find-file
is actually usable on large projects now (e.g. autocomplete Linux kernel would take ~5 seconds to show up, now shows up instantly).