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

Add option to ignore nested git repositories #2751

Closed

Conversation

zaneduffield
Copy link

This implements the suggestion made in #23 to provide an option to ignore nested git repositories.

A nested git repository is identified by the presence of a .git file or directory. It's a directory in the regular case, but it's a file for git worktrees and git submodules.

This option is disabled by default.

I'm open to suggestions for better names for things. In particular I'm not sure about the name ignore_nested_git_repo used in IgnoreOptions and IgnoreBuilder because the concept of 'nesting' is outside of that layer; it has no knowledge of the level of a DirEntry and relies on the calling code to make sure that the level 0 directory is never ignored.

This implements the suggestion made in BurntSushi#23 to provide an option to ignore nested
git repositories.

A nested git repository is identified by the presence of a .git file or
directory. It's a directory in the regular case, but it's a file for git
worktrees and git submodules.

This option is disabled by default.
@mvnetbiz
Copy link

I'm successfully using this in one of my repos with submodules. Thanks!

@ndavd
Copy link

ndavd commented Oct 6, 2024

Any updates on this?

@zaneduffield
Copy link
Author

It seems like there isn't much interest in getting this merged. I'm closing it for now.
Anyone can pick this back up if they want.

@ltrzesniewski
Copy link
Contributor

FWIW, the maintainer has little time to review PRs, and merges them by rollups when he finds time for that. I'd let this open if you still want this to be merged.

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.

4 participants