libgit2 / libgit2/libgit2sharp
Repository.Reset doesn't checkout files having only a single line's line ending changed
未关闭
还没有人认领这个 Issue。
- 主要语言
- C#
- 星标
- 3.5k
- 派生
- 925
- PR 合并指标
- 30 天内没有已合并 PR
描述
If the line ending of only one line somewhere in the middle of a file, the file is not detected as Dirty by the reset method and the change is not reverted after calling it.
On the other hand Repository.RetrieveStatus correctly returns the file as modified
I'm attaching a test repo which shows the issue with version v0.22 from NuGet (Note that I had to change the zip file's extension to txt because otherwise GitHub rejected it for some reason...).
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从附带的测试仓库以及 Repository.Reset 和 Repository.RetrieveStatus 入口点开始。比较它们各自如何处理一个行尾发生更改的文件;完成的标准是 Reset 将该文件检测为 Dirty 并还原该更改,同时有一个覆盖此情况的回归测试。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- csharp, git
- 领域
- devtools
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100