Created
May 24, 2011 18:21
-
-
Save bradfordcp/989308 to your computer and use it in GitHub Desktop.
Pre-commit git hook to regenerate documentation and add it to the commit
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
inm-bradfordcp-mbp:some_folder bradfordcp$ cat .git/hooks/pre-commit | |
#!/bin/sh | |
# | |
# Regenerates documentation and adds it to the commit | |
# | |
echo | |
echo "Regenerating Documentation" | |
echo | |
rake doc:generate | |
echo | |
echo | |
echo "Regeneration complete" | |
echo | |
echo "Adding updated docs to commit" | |
echo | |
git add docs | |
git add -u docs | |
echo |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment