Skip to content
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

HUSKY=0 does not stop Husky on Windows #1502

Open
johan-byggtjanst opened this issue Aug 29, 2024 · 2 comments
Open

HUSKY=0 does not stop Husky on Windows #1502

johan-byggtjanst opened this issue Aug 29, 2024 · 2 comments

Comments

@johan-byggtjanst
Copy link

** Problem **
When using Husky on Windows and setting HUSKY=0 the pre-push hooks should not run but they did.

Context

  • Using Windows terminal.
  • Husky 8.0.3

This should be possible to test with just a pre-push hook that does "echo The pre-push hook ran".

Thank you!

@typicode
Copy link
Owner

typicode commented Sep 3, 2024

Seems surprising. I would maybe suggest trying to upgrade and verify that the env variable was correctly set by adding echo $HUSKY in your pre-push

@AaaStrky
Copy link

I have similar problem with husky v9.1.6 on windows.
Even with husky=0 it will still run hooks.

Also need to add #!/usr/bin/env sh to my pre-commit or it randomly run to an error: cannot spawn .husky/pre-commit: No such file or directory

Screenshot_22

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants