Add .gitattributes to avoid line endings issues

Since commit 56e687f4979d, Linux line endings (LF) are enforced. But on
Windows, a common practice is to set core.autocrlf to 'auto', wich mean
that the local copy of the file has Windows line endings, whereas the
remote copy has Linux line endings (cf. 
https://help.github.com/articles/dealing-with-line-endings/#platform-windows).

With core.autoclrf=auto, Checkstyle will throw an error because local
files will have Windows line endings.

This setting will set Linux line endings for all text files, except
.cmd files.


Project: http://git-wip-us.apache.org/repos/asf/jclouds/repo
Commit: http://git-wip-us.apache.org/repos/asf/jclouds/commit/99c5b9ac
Tree: http://git-wip-us.apache.org/repos/asf/jclouds/tree/99c5b9ac
Diff: http://git-wip-us.apache.org/repos/asf/jclouds/diff/99c5b9ac

Branch: refs/heads/master
Commit: 99c5b9ace7491afbe4ad511fc3b9fd3b849dcd57
Parents: c73b82b
Author: olivierlemasle <[email protected]>
Authored: Sun Oct 4 20:47:35 2015 +0200
Committer: Ignasi Barrera <[email protected]>
Committed: Wed Oct 7 20:43:55 2015 +0200

----------------------------------------------------------------------
 .gitattributes | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jclouds/blob/99c5b9ac/.gitattributes
----------------------------------------------------------------------
diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..6008505
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,2 @@
+* text eol=lf
+*.cmd binary

Reply via email to