-
Notifications
You must be signed in to change notification settings - Fork 55
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
Don't try to apply format on merge commits #23
Comments
Are you using a recent version of the script? This should have been fixed in commit |
Strange, I should have latest. I will verify next week at work and try to debug. Thank you! |
I do have changes from that PR. I added
If it changes anything: my repo is cloned into Anyway seems to me that check is not performed. When done manually:
|
PR #18 Only adds suggestion "You appear to be committing the result of a merge. It is not recommended....". |
Ah good point! |
Most our code is not formatted. We want to "get there" by steps, so we use this hook to format modified code and even then it is not always used.
When merge happens (I pull upstream changes to my topic branch), hook tries to format everything I pulled in the merge. If there is a lot of changes, format takes a lot of time. I would like it to just ignore merging commits. Even though formatting is right thing to do, merge commit is not a good time for it.
Ideas for detecting merge commits are here: https://stackoverflow.com/questions/27800512/bypass-pre-commit-hook-for-merge-commits
The text was updated successfully, but these errors were encountered: