Automating tasks and improving developer workflow with pre-commit git hooks

Probably the most usual git workflow is adding changes to the staging area, committing them, and pushing them to the remote repository. Depending on the project we are working on there are some things that we should be checking, validating or generating before heading for the commit. That’s where pre-commit hooks come in.