Replies: 3 comments 4 replies
-
|
I think I can add a flag |
Beta Was this translation helpful? Give feedback.
-
|
@mrexox The That said, I am okay with closing this discussion if you are as well. |
Beta Was this translation helpful? Give feedback.
-
|
Could this be added to the main .lefthook config file ? everytime i execute Created feature-request |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
TL;DR Is it possible to run a
lefthookhook without the.git/hooksdirectory being modified?We've recently switched from using
git hookscombined withlint-stagedto solely usinglefthookin our monorepo. This change was implemented to streamline managing and executing multiple linters simultaneously during our CI process. Which by usinglefthookhas made it very easy and clean to do! 🙌We then encountered a problem where our CI runners were inadvertently syncing the
git hooksthat affected the auto-commit linter fixes, leading to failures.To address this, we configured
lefthookto skip all hooks in the CI environment except for the specific ones needed, using askipoption in therunsettings.Despite solving the issue, we are curious if there is a simpler solution. Specifically, we want to know if there's a way selectively execute certain hooks in a CI environment without triggering the entire install script.
lefthook/internal/lefthook/install.go
Lines 111 to 191 in 1d100c6
Beta Was this translation helpful? Give feedback.
All reactions