commitizen / commitizen/cz-cli
Comittizen runs twice when using the `prepare-commit-msg` hook
Offen
- Vorherrschende Sprache
- JavaScript
- Sterne
- 17.5k
- Forks
- 566
- Ø Merge
- 8 Std. 16 Min.
- Gemergte PRs (30 T.)
- 1
Beschreibung
Steps to re-produce
1. Create a `prepare-commit-msg` hook:
``` #sh
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
exec < /dev/tty && node_modules/.bin/cz --hook || true
```
2. Run `git commit`
3. Follow the CLI
4. Everything works as expected.
5. Run `git cz`
6. Follow the CLI
7. Everything goes as expected except that, after we complete the wizard, Comittizen opens up again.
Is there any way to prevent `prepare-commit-msg` hook from running when executing `git cz`?
Beitragsleitfaden
Bewertung
Dieses Issue wurde noch nicht bewertet.