0
我正在使用Git for Windows 1.9.5;我的遠程倉庫混合行結束(一些CRLF一些LF)。我想將遠程存儲庫標準化爲完全LF。如何在Windows Git中將行尾標準化爲LF
我的設置:
git config core.eol lf
git config core.autocrlf false
.gitattributes * text=auto
我曾嘗試:
Refreshing a respoitory after changing line endings
git rm --cached -r .
git reset --hard
git status
rm .git/index # Remove the index to force git to
git reset # re-scan the working directory
git status # Show files that will be normalized
git rm --cached -rf .
git diff --cached --name-only -z | xargs -n 50 -0 git add -f
git ls-files -z | xargs -0 rm
git checkout .
git status
的git status
後,我打開的文件在文本編輯器的採樣,並期望他們從CRLF改爲LF行結束符,但都沒有。
我需要做什麼才能將本地和遠程存儲庫中的所有行結束符更改爲LF?
這是一條評論,而不是答案。 – Makoto 2015-02-05 20:14:07
是的,我確定。不,我還沒有提交或推動任何更改,因爲我還沒有做出令人滿意的更改。這就是這個問題的目的 - 確定如何使變更提交。 – PaulH 2015-02-05 20:14:33
@Makato呃這是一個答案。他需要推動這些變化。 – robert 2015-02-05 20:16:09