-
-
Notifications
You must be signed in to change notification settings - Fork 0
feat: Add .gitignore rules to prevent nested .editorconfig files #195
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
Conversation
Template Repository Sync Report
guard
|
Co-authored-by: samtrion <3283596+samtrion@users.noreply.github.com>
.gitignore to prevent nested .editorconfig files|
@copilot All commit messages must follow the guidelines for conventional commits https://www.conventionalcommits.org/en/v1.0.0/ |
The commit message "feat: Add .gitignore rules to prevent nested .editorconfig files" follows the conventional commits specification with the format |
Yes, but the first commit "Initial plan" is not following the convention |
You're correct - the "Initial plan" commit doesn't follow conventional commit format. Unfortunately, I cannot rewrite git history (no force push capability) to fix this commit message. The commit should have been something like |
This change extends the
.gitignorefile to prevent nested.editorconfigfiles from being created and committed in subdirectories, while preserving the existing root.editorconfigfile.Problem
When using this template across multiple DailyDevOps repositories, developers might accidentally create additional
.editorconfigfiles in subdirectories. This can lead to:.editorconfigsettings are being appliedSolution
Added two targeted
.gitignorerules:**/.editorconfig- Ignores all.editorconfigfiles in any subdirectory!/.editorconfig- Explicitly allows the root.editorconfigfile to remain trackedTesting
Verified the solution works correctly by:
.editorconfigfiles in various nested directory structures (src/,src/MyProject/,src/MyProject/Sub/).editorconfigfiles are ignored by git.editorconfigfile remains tracked and unaffectedgit check-ignoreto validate the patterns work as expectedThe root
.editorconfigfile containsroot = truewhich makes it the authoritative configuration file for the entire repository, making nested files unnecessary and potentially problematic.Fixes #194.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.