opencommit
opencommit copied to clipboard
[Bug]: rebasing is painfully slow with opencommit hook set
Opencommit Version
3.2.7
Node Version
v22.16.0
NPM Version
10.9.2
What OS are you seeing the problem on?
Other Linux Distro
What happened?
when rebasing my repositories with the prepare-commit-msg hook, i get the following behavior, where each commit applied takes about one second because of opencommit:
as a result, rebases can take a painstaking amount of time, whereas without the hook, they take only a second.
Expected Behavior
i would like opencommit to exit from its script as early as possible during rebases.
Current Behavior
opencommit doesn't exit early during rebases; it seems to be checking for updates for each pick command in a rebase, which greatly slows down the rebase operation.
Possible Solution
check for rebasing as early as possible in the git hook script, and exit immediately if so.
Steps to Reproduce
git switch -cto a new branch that you can safely mess up with a rebaseoco hook setgit rebase -i HEAD~30- rearrange or drop an early commit
- observe that
ocodrastically slows down rebase time
Relevant log output