adds pre-commit
better error messages