Created
October 22, 2012 19:37
-
-
Save rinatkhaziev/3933584 to your computer and use it in GitHub Desktop.
Easily sync updates from a git repo to a svn repo
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 | |
#use it like this: git-to-svn.sh /path/to/git/repo /path/to/svn/trunk | |
if [ -z "$1" ]; then | |
printf "\033[31;40mYou haven\'t specified the path to copy from\n" | |
printf "\033[00m" | |
fi | |
if [ -z "$2" ]; then | |
printf "\033[31;40mYou haven\'t specified the path to copy to\n" | |
printf "\033[00m" | |
exit | |
fi | |
rsync -avz --exclude=.git* --exclude=*.phptidy-cache --exclude=.DS_Store ${1%/}/ ${2%/} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment