Open BestDI opened 4 years ago
git remote -v 查看所有远程仓库, git remote xxx 查看指定远程仓库地址 git remote set-url origin http://****/git_test.git
git remote rm origin git remote set-url origin http://****/git_test.git
进入 /.git
/.git
vim config [core] repositoryformatversion = 0 filemode = true logallrefupdates = true precomposeunicode = true [remote "origin"] url = git remote set-url origin http://****/git_test.git fetch = +refs/heads/*:refs/remotes/origin/* [branch "master"] remote = origin merge = refs/heads/master
修改 [remote “origin”]下面的url即可
git 远程仓库地址变更本地修改
🎲 1. 通过命令直接修改远程地址
2. 通过命令先删除再添加远程仓库
3. 直接修改配置文件
进入
/.git
修改 [remote “origin”]下面的url即可