You'll need to make sure that you have pre-commit setup and installed in your environment by running these commands:
pre-commit
pre-commit install --hook-type commit-msg