由于某种原因,我无法重置我的git工作目录中的一个特定文件!
开始:
我做了一个git reset - 现在,
$ git reset --hard
HEAD is now at 97b3164 Added clojure jars for personal tracking and also set clo
jure classpath in jaskirat.el
Run Code Online (Sandbox Code Playgroud)
硬重置后:
$ git status
# On branch master
# Changed but not updated:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: elpa-to-submit/color-theme.el
#
no changes added to commit (use "git add" and/or "git commit -a")
Run Code Online (Sandbox Code Playgroud)
我也试过git checkout - elpa-to-submit/color-theme.el但似乎没有什么能让我回到一个"干净"的未分级工作目录!:-S
注意:我的linux桌面上也有来自github的这个repo的克隆,我在桌面上看不到这样的问题
根据您的git diff反馈,这似乎是一个EOL问题.Windows使用\r\n,而Linux使用\n.见core.eol,core.safecrlf并且core.autocrlf在设置git-config(1).
| 归档时间: |
|
| 查看次数: |
1068 次 |
| 最近记录: |