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

Move to ignore for ignoring files #640

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

drahnr
Copy link
Contributor

@drahnr drahnr commented Jul 30, 2024

Closes #619

A pragmatic and practical fix to slow performance on directories with large target dirs et.al. (form doesn't terminate to milliseconds for 100GB+ target directory)

Also avoids a bunch of unnecessary collections and passes around an iterator instead, with the according file rename.

Comment on lines +136 to +141
bldr.git_ignore(true)
.git_exclude(true)
.git_global(true)
.ignore(true)
.hidden(false)
.same_file_system(true);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel the same as you that obeying gitignore rules is likely a desired behavior and i personally have nothing against this becoming the default behavior (one day)

however, I agree with @panekj #619 (comment) that this can be viewed as a breaking change, so would be better to have this as an opt-in feature, at least for now.

Also, given how ignore API is designed -- some ignore rules by default -- the walk builder should be configured with standard_filters(false) first, then enable what we want.

Question
is switching to ignore create sufficient to prune large target directly without recursing to it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is switching to ignore create sufficient to prune large target directly without recursing to it?

Yes it is

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

Successfully merging this pull request may close these issues.

taplo-cli very slow at collecting files
2 participants