'How do I change the GitHub URL in Visual Studio?
I know this is probably a really dumb question, but I can't figure it out. When you go to your branches, right click on one, and click publish, the first time it asks you for a URL and I put in the wrong one (one that doesn't even exist haha). So now whenever I try to publish a branch, it says it can't find it and I don't know how to change the URL because the option doesn't come up anymore.
Solution 1:[1]
- Go to your repo directory at C or D disk.
- Change your directory settings to display hidden files from top of Windows Explorer.
- Open .git directory, then display "config" file.
- Open "config" file and change "[remote "origin"] url" row which is like; " ... [remote "origin"] url = https://[email protected]/x/xxx.git ... "
- using new git repo address at Visual Studio
Solution 2:[2]
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | ishakkulekci |
| Solution 2 | Abdulla Sirajudeen |



