Consider replacing overcommit with another git hooks manager
What is the GitLab engineering productivity problem to solve?
Overcommit can be problematic if you don't have the Ruby version for the current branch. For example:
OVERCOMMIT_DISABLE=1 git rebase ...doesn't work if you don't have the Ruby version installed for the current branch
😕 workaround: edit .ruby-version, commit, rebase, remove last commit
Additionally there are more performant git hook managers.
Problem identification checklist
-
The root cause of the problem is identified. -
The surface of the problem is as small as possible.
What are the potential solutions?
-
Lefthook - ~20% more performant when using the discourse codebase: https://github.com/Arkweid/lefthook/wiki/Benchmark-lefthook-vs-overcommit
-
All potential solutions are listed. -
A solution has been chosen for the first iteration: PUT THE CHOSEN SOLUTION HERE
Verify that the solution has improved the situation
-
The solution improved the situation. - If yes, check this box and close the issue. Well done!
🎉 - Otherwise, create a new "Productivity Improvement" issue. You can re-use the description from this issue, but obviously another solution should be chosen this time.
- If yes, check this box and close the issue. Well done!
Edited by Kyle Wiebers