Skip to content

Instantly share code, notes, and snippets.

@napsy
Created April 25, 2011 09:26
Show Gist options
  • Save napsy/940308 to your computer and use it in GitHub Desktop.
Save napsy/940308 to your computer and use it in GitHub Desktop.
Quickly switch svn repository URL
#!/bin/bash
if [ $# -eq 0 ]
then
echo "$0 [home|office]"
exit
fi
if [ $1 == "home" ]
then
OLD="XXX"
NEW="YYY"
elif [ $1 == "office" ]
then
OLD="YYY"
NEW="XXX"
fi
echo "SVN switching from $OLD to $NEW"
svn switch --relocate https://$OLD/trunk https://$NEW/trunk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment