diff options
Diffstat (limited to '.gitattributes')
-rw-r--r-- | .gitattributes | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/.gitattributes b/.gitattributes index bcea0290f4..cabbb1732c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,16 +1,16 @@ # Treat all files in the Go repo as binary, with no git magic updating -# line endings. Windows users contributing to Go will need to use a -# modern version of git and editors capable of LF line endings. +# line endings. This produces predictable results in different environments. +# +# Windows users contributing to Go will need to use a modern version +# of git and editors capable of LF line endings. +# +# Windows .bat files are known to have multiple bugs when run with LF +# endings, and so they are checked in with CRLF endings, with a test +# in test/winbatch.go to catch problems. (See golang.org/issue/37791.) # # We'll prevent accidental CRLF line endings from entering the repo -# via the git-review gofmt checks. +# via the git-codereview gofmt checks and tests. # -# See golang.org/issue/9281 +# See golang.org/issue/9281. * -text - -# The only exception is Windows files that must absolutely be CRLF or -# might not work. Batch files are known to have multiple bugs when run -# with LF endings. See golang.org/issue/37791 for more information. - -*.bat text eol=crlf |