]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
.gitattributes: Enforce LF line-endings on all non-binary files
authorDeniz Bahadir <deniz@code.bahadir.email>
Wed, 24 Apr 2024 14:37:34 +0000 (16:37 +0200)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Wed, 19 Jun 2024 12:15:54 +0000 (14:15 +0200)
Although Git is able to automatically modify line-endings during checkin
and checkout, this brings a lot of trouble, especially when trying to
use a repository from different platforms (as Windows and Linux). This
is due to the fact that Git consults different local gitconfig settings
and uses problematic defaults if not set.

Therefore, Git should enfoce one type of line-ending (LF) and not
consult the local config, which is what the change from this commit
does.

Signed-off-by: Deniz Bahadir <deniz@code.bahadir.email>
.gitattributes

index ac21ec4592dbe7a78c810e2df709bf9d6a8d3951..38fd673cc9e488e364d27a71102599fcc237bbc4 100644 (file)
@@ -1,8 +1,9 @@
-* text=auto
-*.abi text eol=lf
-*.c text
-*.h text
-*.sh text eol=lf
+# By default, enforce LF line-endings on all files that are not considered binary files!
+* text=auto eol=lf
+
 crc32_braid_tbl.h hooks-max-size=1000000
-Makefile text
-configure text eol=lf
+
+# Don't export git/github-related files in tar/zip archives
+/.github export-ignore
+.gitattributes export-ignore
+.gitignore export-ignore