Put this in a file called pre-commit
in .git/hooks/
#!/bin/sh
# To enable this hook, rename this file to "pre-commit".
git rev-list --count master > build_number
git add build_number
Put this in a file called pre-commit
in .git/hooks/
#!/bin/sh
# To enable this hook, rename this file to "pre-commit".
git rev-list --count master > build_number
git add build_number