Description
The pre-commit scripts test and format rely on /bin/sh, which does not exist on Windows (at least the path). This is a non-portable shebang, which can be fixed by using #!/usr/bin/env sh instead.
Steps to reproduce
- Follow the Contributing steps to:
(a) Fork the repo, install dependencies through poetry, and setup the pre-commit hooks
- Run
pre-commit run --all
Current behavior
On Windows, the pre-commit hooks format and linter and test fail with the error message Executable '/bin/sh' not found.
Desired behavior
The pre-commit hooks are able to run the provided shell scripts.
Screenshots

Environment
Commitizen Version: 2.35.0
Python Version: 3.8.10 (tags/v3.8.10:3d8993a, May 3 2021, 11:48:03) [MSC v.1928 64 bit (AMD64)]
Operating System: Windows
Description
The
pre-commitscriptstestandformatrely on/bin/sh, which does not exist on Windows (at least the path). This is a non-portable shebang, which can be fixed by using#!/usr/bin/env shinstead.Steps to reproduce
(a) Fork the repo, install dependencies through
poetry, and setup thepre-commithookspre-commit run --allCurrent behavior
On Windows, the
pre-commithooksformatandlinter and testfail with the error messageExecutable '/bin/sh' not found.Desired behavior
The
pre-commithooks are able to run the provided shell scripts.Screenshots
Environment
Commitizen Version: 2.35.0
Python Version: 3.8.10 (tags/v3.8.10:3d8993a, May 3 2021, 11:48:03) [MSC v.1928 64 bit (AMD64)]
Operating System: Windows