Created
January 25, 2012 00:27
-
-
Save nacin/1673766 to your computer and use it in GitHub Desktop.
Require `svn ci -m` calls to have explicit files
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
#!/bin/sh | |
function svn() { | |
if [ "$1" == "ci" ] && [ "$2" == "-m" ] && [ -z "$4" ] && [ "$(svn stat --ignore-externals | grep '^[^?X]' | wc -l | awk '{print $1}')" -gt 1 ]; then | |
svn stat --ignore-externals | grep '^[^?X]' | |
echo "" | |
echo $3 | |
echo "" | |
echo "Unbounded commit... What are you doing, man?" | |
else | |
/usr/bin/svn "$@" | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment