【发布时间】:2017-06-18 22:05:34
【问题描述】:
我有一个带有两个分支的 git 存储库:master 和 master2。如果我想 将所有现有文件从 master 传递到 master2,我应该使用什么命令?我试过这个,但它没有用
git checkout master2
git checkout master files
git commit -m 'Add file files to master2.'
【问题讨论】:
-
从master合并到master2不是更简单吗?
-
这是您通常对合并执行的操作。 What's your reason for wanting to do this? 可能有更好的方法来解决您的实际问题。
标签: git github command-line