How can I change the remote/target repository URL on Windows?

user169320 picture user169320 · Nov 26, 2009 · Viewed 169.4k times · Source

I created a local GIT repository on Windows. Let's call it AAA. I staged, committed, and pushed the contents to GitHub. [email protected]:username/AAA.git

I realized I made a mistake with the name.

On GitHub, I renamed it to [email protected]:username/BBB.git

Now, on my Windows machine, I need to change [email protected]:username/AAA.git to [email protected]:username/BBB.git because the settings are still trying to "push" to [email protected]:username/AAA.git but I need to push to [email protected]:username/BBB.git now.

How could I do that?

Answer

hallucinations picture hallucinations · Dec 30, 2011
git remote set-url origin <URL>