如果我的机器上有两个 git 项目 有两个不同的项目名称
我可以在这样的两个目录中使用这段代码来管理它吗
/foo1$ git remote add origin git@github.com:username/ProjectName-1
/foo2$ git remote add origin git@github.com:username/ProjectName-2
它是存储在目录中还是系统中的 git 配置文件中?
最佳答案
信息存储在每个存储库(项目)的 .git/config
文件中。
是您通过将 Remote 分别添加到每个存储库来做正确的事情。
关于GitHub git 远程添加源 git@github.com :username/ProjectName a one time process?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1833258/