본문 바로가기
Git

Git] The text is identical, but the files do not match!

by Fastlane 2023. 3. 22.
728x90
반응형

서버에서 일괄 최신 소스를 다운받아 git commit 하려고 할때 

변경파일이 많아서 확인해보니 아래와 같은 메시지를 확인하였다. 

 

The text is identical, but the files do not match! The following differences were founc: Newlines

 

 

해결방법 : 

$ git config --global core.autocrlf true
# Configure Git to ensure line endings in files you checkout are correct for Windows.
# For compatibility, line endings are converted to Unix style when you commit files.
$ git add --renormalize .
# 변경된 모든 파일을 다시 추가하고 줄 끝을 정규화합니다.
$ git status
# 다시 작성된 정규화된 파일을 표시합니다.

 

728x90
반응형

'Git' 카테고리의 다른 글

Git] alias  (0) 2024.04.29
Git] vim editor - Edit Multiple Line  (0) 2024.04.29
GitLab CI/CD] 4. rsync로 웹서버에 파일전송하기  (0) 2022.12.30
Git의 원리] 8. git tag 원리  (0) 2022.09.08
Git의 원리] 7. git tag 기본 사용법  (0) 2022.09.08

댓글