简体   繁体   English

分支修改GIT存储库中的代码

[英]Branching modifies code in GIT repo

Our GIT repo has ended up in a weird state. 我们的GIT回购已陷入怪异状态。 If I branch off the develop branch, and immediately diff the new branch with develop, they differ. 如果我退出了develop分支,并立即将新分支与develop进行区分,则它们会有所不同。 The new branch contains an old bug which has been fixed in the develop branch. 新分支包含一个旧错误,已在开发分支中修复。 This is all done locally using SourceTree and the latest develop branch from remote repo. 全部使用SourceTree和远程回购中的最新开发分支在本地完成。 My teammate experienced the same thing, so it can't be just my local repo being corrupt. 我的队友也经历过同样的事情,所以不仅仅是我的本地存储被破坏了。 How is this possible, and what could be done to fix it? 这怎么可能?如何解决?

Your local repository is probably "compromised". 您的本地存储库可能已“受损”。 Clone it (in another folder) and checkout the develop branch to see if they still differ. 克隆它(在另一个文件夹中)并检出develop分支以查看它们是否仍然不同。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM