首页
注册
登录
V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请
登录
V2EX
›
程序员
为什么git reset --hard无法重置工作区的若干个文件?
forgottencoast
·
2013-11-23 17:08:36 +08:00
· 6749 次点击
这是一个创建于 3983 天前的主题,其中的信息可能已经有所发展或是发生改变。
git checkout也不行,总有3个文件没有被还原。
这3哥文件已跟踪,git status -s显示第二列M。
第 1 条附言 ·
2013-11-23 19:21:37 +08:00
问题解决,参见:http://stackoverflow.com/questions/11383094/unstaged-changes-left-after-git-reset-hard
git
文件
第二列
3 条回复
•
2019-11-16 23:37:41 +08:00
1
4code1
2013-11-24 11:41:43 +08:00
试试 git clean -dxf
2
msg7086
2013-11-24 12:33:24 +08:00
多数就是行尾cr/lf的问题。其实diff一下就知道问题在哪了
3
chengcheng222e
2019-11-16 23:37:41 +08:00
git config core.filemode false 这个搞定
关于
·
帮助文档
·
博客
·
API
·
FAQ
·
实用小工具
·
1877 人在线
最高记录 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 26ms ·
UTC 00:47
·
PVG 08:47
·
LAX 17:47
·
JFK 20:47
Developed with
CodeLauncher
♥ Do have faith in what you're doing.