当我知道主分支和 tfs/default 发生更改时,git tfs checkin 工具显示 'nothing to commit'

标签 git tfs

我最近刚刚启动 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/

相关文章:

git - git merge --squash 和 git cherry-pick 有什么区别?

Git fatal error : bad object refs/heads 2/master

git - 将 Jino 部署到 Heroku?

Git 删除 TFS git 存储库中的远程分支

TFS 2010 构建服务

git - 使用 gitlist 推送到私有(private) gitserver

macos - 如何从 Git 存储库中删除 .DS_Store 文件?

c# - TFS 构建服务器在警告 "Cannot find the last label"后卡住

visual-studio - TFS SourceControl 从主干分支合并

visual-studio - 无法在 TFS 2012 中更改工作区设置(服务器到本地)