Closed gabyx closed 5 years ago
Any particular parts you think are slow? I would think running the actual hooks is usually slower than the overhead Githooks adds, but happy to look at particular features if you have examples.
I love Go, but I think Posix Shell is just fine for a project like this as well, so not really looking at a rewrite - for now at least.
Hm.. do you know how to profile bash scripts ? :-), really hard brain teaser? set -x
helps but, At the end it would be good to have a notion about which function was the most time consuming :-)
The project is enough simple to be really good understandable, which is plus. If it becomes Go, it gets more complicated I think :)...
Yeah, though it would also be more testable. But less run-the-same-everywhere crossplatform. So there's pros and cons.
What I wanted to point at is that if there are slow places in the code, I'm happy to look at them, and if the only way to make them faster is to rewrite them in Go for example, then I'll look at that. Otherwise I'm happy with the state of the code for now.
Closing this now but feel free to open a new issue if you find slow parts that need looking at!
I realized, the speed of githooks is somewhat acceptable but not soo fast on Windows Git Bash... I was wondering, if that project would benefit from beeing ported to Go ;). Or do you have any other idea how to make it fast, or what was your experience?
I mean the lefthook project is good but lacks some awesome features in this repo. (Shared Hooks ...), Proper global install, safety on clone, internal LFS...)