Skip to content

Ignore config file from hidden directory#677

Merged
j178 merged 2 commits intomasterfrom
ignore-hidden
Sep 8, 2025
Merged

Ignore config file from hidden directory#677
j178 merged 2 commits intomasterfrom
ignore-hidden

Conversation

@j178
Copy link
Owner

@j178 j178 commented Sep 8, 2025

No description provided.

@j178 j178 added the enhancement New feature or request label Sep 8, 2025
@codecov
Copy link

codecov bot commented Sep 8, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.57%. Comparing base (bc1b423) to head (8cedc4b).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #677      +/-   ##
==========================================
+ Coverage   87.51%   87.57%   +0.06%     
==========================================
  Files          58       58              
  Lines       10266    10265       -1     
==========================================
+ Hits         8984     8990       +6     
+ Misses       1282     1275       -7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@j178 j178 merged commit 2a67f7c into master Sep 8, 2025
25 of 26 checks passed
@j178 j178 deleted the ignore-hidden branch September 8, 2025 12:23
@potiuk
Copy link

potiuk commented Sep 8, 2025

That is a bit problematic for us as we have a .pre-commi-config.yaml already in .gitHub - but I guess it's a good call, we can move it

@j178
Copy link
Owner Author

j178 commented Sep 8, 2025

we can move it

@potiuk This PR stops auto-discovery of the .pre-commit-config.yaml file in hidden directories. Having it there makes the directory a project, but that doesn’t seem right for something like .github, does it? I think it’s always used with the -c option, so this PR won’t affect that.

@potiuk
Copy link

potiuk commented Sep 8, 2025

we can move it

@potiuk This PR stops auto-discovery of the .pre-commit-config.yaml file in hidden directories. Having it there makes the directory a project, but that doesn’t seem right for something like .github, does it? I think it’s always used with the -c option, so this PR won’t affect that.

No worries. I already moved it. We do want this check to be run at git commit but it can be easily done in other non-hidden repository. The only reason we separated it originally (without monorepo support) was that it required Python 3.11 due to octopin needing it, and all the rest of our hooks are Python 3.10+ (because all our code is Python 3.10+) - but if we could run it from main .pre-commit-config.yaml, we would.

Now with monorepo support we want to run it automatically on git commit - but it's perfectly fine to move it to another directory as well. Not following hidden directories makes it much more performant to search to through checked out repo, so it's a good call I think.

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

Successfully merging this pull request may close these issues.

2 participants