Created
November 19, 2016 07:32
-
-
Save dahoba/c6aeaa53695e1a30e6fbe2d7e402561a to your computer and use it in GitHub Desktop.
Git attribute to deal with cross-platform line endings (Linux, macOS, Window)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Set the default behavior, in case people don't have core.autocrlf set. | |
* text=auto | |
# Explicitly declare text files you want to always be normalized and converted | |
# to native line endings on checkout. | |
*.c eol=crlf | |
*.h eol=crlf | |
*.cpp eol=crlf | |
*.rc eol=crlf | |
*.vcproj eol=crlf | |
*.bat eol=crlf | |
# Declare files that will always have CRLF line endings on checkout. | |
*.sln text eol=crlf | |
# Denote all files that are truly binary and should not be modified. | |
*.png binary | |
*.jpg binary | |
*.gif binary | |
*.ts text eol=lf | |
*.js text eol=lf |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment