Git changes being lost - why?

后端 未结 9 1830
梦如初夏
梦如初夏 2021-02-13 20:42

Our development team is using git and we\'ve lost changes to files at least twice recently. We are using private Github repos.

In the current case, we can go back throug

9条回答
  •  时光取名叫无心
    2021-02-13 21:28

    My guess is that there are different configuration among committers, perhaps someone is missing an autocrlf configuration.

    Git somehow considers completely different two revisions of the same file, thus overwriting the old one with newer changes from another branch.

    If a three-way merge (default recursive one) finds two completely different childs (ie because of CRLF misconfiguration) the merged result will be the most recent one, with no conflicts.

提交回复
热议问题