关联和修改Git远程仓库

308 阅读1分钟
// 无远程仓库地址时,添加关联
git remote add origin 远程仓库url       // 添加远程仓库地址
// 已有远程仓库地址时,修改设置
git remote set-url origin 远程仓库url   // 设置远程仓库地址

// 附加内容
git remote get-url origin               // 查看远程仓库地址
git remote                              // 查看远程仓库名称