Created
October 12, 2010 00:17
-
-
Save robertwalker/621450 to your computer and use it in GitHub Desktop.
Remove Xcode build dir when switching branches
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/bash | |
# | |
# Post-checkout script to remove Xcode build directory when | |
# checkout out from a branch. | |
# | |
# post-checkout args | |
# <prev HEAD> <new HEAD> <changing branches, flag=1> | |
# | |
BUILD_DIR='build' | |
if [ $3 -eq 1 ]; then | |
if [ -d $BUILD_DIR ]; then | |
rm -rf $BUILD_DIR | |
echo "Hook: Removed 'build' folder" | |
fi | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment