Skip to content

Instantly share code, notes, and snippets.

@johnbintz
Created May 10, 2011 20:54
Show Gist options
  • Save johnbintz/965364 to your computer and use it in GitHub Desktop.
Save johnbintz/965364 to your computer and use it in GitHub Desktop.
A way to distribute git hooks with a Rails app and have them easily installed
#!/bin/bash
rspec spec
if [ $? -ne 0 ]; then exit 1; fi
#!/bin/bash
for hook in script/hooks/* ; do
ln -sf $PWD/$hook .git/hooks/${hook##*/}
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment