Created
March 9, 2013 12:31
-
-
Save munen/5124033 to your computer and use it in GitHub Desktop.
Change github username from 'preek' to 'munen' in repository
This file contains hidden or 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
| echo "Showing old remote origin" | |
| git remote -v | |
| echo "--------" | |
| NEW_REMOTE=$(git remote -v | head -n1 | awk '{print $2}' | sed -e 's/preek/munen/') | |
| git remote set-url origin $NEW_REMOTE | |
| if (( $? )); | |
| then echo "failed to set new remote, please adjust manually"; | |
| else echo "succeeded in setting new remote"; | |
| fi | |
| echo "--------" | |
| echo "Showing new remote origin" | |
| git remote -v |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment