This is of course exactly the sort of thing Git was designed to deal with. When I cloned this project from GitHub originally, Git set up a local repository for me, and set the GitHub repo as a remote repository named "origin". Unlike SVN, there's nothing magic about the remote repository - you can have several, and push changes to all of them. The easiest thing to do in this case is just forget about your old origin, and set a new one. Here's a slightly edited command history:
$ git remote -v
origin https://github.com/flashingpumpkin/spooky.git (fetch)
origin https://github.com/flashingpumpkin/spooky.git (push)
$ git remote rm origin
$ git remote -v
$ git remote add origin git@github.com:bluegraybox/spooky.git
$ git remote -v
origin git@github.com:bluegraybox/spooky.git (fetch)
origin git@github.com:bluegraybox/spooky.git (push)
$ git push
Counting objects: 7, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (4/4), done.
Writing objects: 100% (4/4), 506 bytes, done.
Total 4 (delta 3), reused 0 (delta 0)
To git@github.com:bluegraybox/spooky.git
a34ae51..b15781e master -> master
$
Ta-daa!
No comments:
Post a Comment