首页 > git中,克隆好的本地库,能从ssh切换到https吗

git中,克隆好的本地库,能从ssh切换到https吗

用ssh的地址初始化了本地库,能动态切换成https吗?还是要重新clone本地库


git remote remove xxxxx
git remote add xxxxx url

或者

git remote set-url xxxx url


没有问题,重新操作git remote就行了
比如

git remote add <name> https://....

或者

git remote set-url <name> https://...

直接该你的项目目录下.git/conf里url项就ok了

【热门文章】
【热门文章】