commitizen / commitizen/cz-cli

Lint-staged doesn't work with commitizen cli

Offen
#911 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
JavaScript
Sterne
17.5k
Forks
566
Ø Merge
8 Std. 16 Min.
Gemergte PRs (30 T.)
1

Beschreibung

I have hooks setup on my repository via husky and [lint-staged](https://www.npmjs.com/package/lint-staged) which should run the linting and prettier commands automatically before commiting the code.

When I make a normal commit using `git commit -m`, lint-staged works but when commiting using commitizen cli, `yarn cz`
(i have this script setup in package.json)
```
"scripts": {
"commit": "cz"
}
```

Lint-stage doesn't run/ doesn't automatically format the code before the commit. Any work-around for this?

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.