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

Support reading .gitignore if present to ignore paths #77

Closed
nuke-web3 opened this issue Sep 3, 2023 · 3 comments
Closed

Support reading .gitignore if present to ignore paths #77

nuke-web3 opened this issue Sep 3, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@nuke-web3
Copy link
Contributor

Is your feature request related to a problem? Please describe.

I don't want to duplicate the paths listed in .gitignore in mlc config. I would like the option (on by default) to use .gitignore as a baseline, and then respect ignoring any additional paths defined in the config.

Describe the solution you'd like

Ideally detecting this present in the pwd and/or target path to do check on and using it automatically would be great. Alternative patters:

Describe alternatives you've considered

Duplication of the ignore settings in this and other tools 🙃

@becheran becheran added the enhancement New feature or request label Sep 3, 2023
@becheran
Copy link
Owner

becheran commented Sep 3, 2023

Good idea. It would require to add and support the full gitignore syntax in mlc which is currently not the case.

@nuke-web3
Copy link
Contributor Author

nuke-web3 commented Sep 28, 2023

Looks like almost a drop in replacement for https://docs.rs/walkdir/latest/walkdir/ could be https://docs.rs/ignore/latest/ignore/ 🤔 might need some more CLI and config tweaks to select specifics about ignoring things. I suspect almost all users would want to default to ignoring .gitignore and .ignore files.

Actually the latter is just a superset of the former 😝
https://github.com/BurntSushi/ripgrep/blob/master/crates/ignore/Cargo.toml#L30

@becheran
Copy link
Owner

Added optinal .gitignore with: #94

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

No branches or pull requests

2 participants