-
Notifications
You must be signed in to change notification settings - Fork 110
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
Avoid erroneous developer commits to main branch #7585
Conversation
Don't understand this tbh. What's the issue - is it to avoid |
We should never commit to our local When we commit to local This PR will make |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we change the commit message to something like Have pre-commit protect main branch
?
Developers should never commit when main branch is checked out. Commits must happen on a branch, and then pull requests to main branch.
05b517d
to
92d655c
Compare
Fixed! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very good!
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #7585 +/- ##
==========================================
+ Coverage 85.18% 85.20% +0.02%
==========================================
Files 383 383
Lines 23275 23293 +18
Branches 893 879 -14
==========================================
+ Hits 19827 19847 +20
+ Misses 3339 3335 -4
- Partials 109 111 +2 ☔ View full report in Codecov by Sentry. |
Issue
Resolves developers forgetting to checkout a new branch before commiting.
Approach
pre-commit
Example of classical developer error that is guarded by this commit:
When applicable