These are scripts executed by Git at specific steps of the version control workflow, depending on their name.
pre-commit
runs before attempting to commit, and prevents committing to the local master branch.
To install,
$ ./install_hooks.bash
To read more about hooks, read the Pro Git chapter.