我最近刚刚启动 git-tfs 桥接,直到最近似乎工作正常一段时间:
这是我的工作流程:
1) git tfs 克隆
2)我创建我的工作分支
3)git checkout工作分支
4)我开始做出改变,然后我 promise )
5)我做了一个 git checkout master,git mergeworking_branch
6)然后执行 git tfs checkintool
不过在 checkin 时,我只选择了几个文件,而不是所有文件。
7) 然后我执行 git tfs fetch 和 git rebase tfs/default
如何提交那些在之前的提交中未选中的文件,因为它现在认为没有提交,并且 tfs/default 和 master 似乎相同且没有更改
最佳答案
根据explanation在 git-tfs 组上,git tfs checkintool 不应该用于部分 checkin (甚至可能导致丢失您选择不提交的文件中的修改):
Checkintool is just a convenient tool to make last minute review of your changes and is not supposed to select things to checkin. If you need to divide changes into two chunks - use git's features that is much more powerful than TFS's ones. For example, if you want to divide commit in two, do a soft reset to previous commit and commit things to two commits. Then execute git tfs rcheckin and you'll have these two commits in the TFS as well.
关于当我知道主分支和 tfs/default 发生更改时,git tfs checkin 工具显示 'nothing to commit',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8128826/