-
Notifications
You must be signed in to change notification settings - Fork 8
/
.gitattributes
49 lines (43 loc) · 2.34 KB
/
.gitattributes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Have files identified as text files converted to lf on checkin and keep lf on
# checkout
* text=auto eol=lf
# Documentation:
# Checkin:
# https://www.git-scm.com/docs/gitattributes
# When text is set to "auto" ... its line endings are normalized to LF on checkin.
# ...
# If you want to ensure that text files that any contributor introduces to the
# repository have their line endings normalized, you can set the text attribute
# to "auto" for all files.
# * text=auto
# Checkout:
# https://www.git-scm.com/docs/gitattributes
# To control what line ending style is used in the working directory, use the eol attribute
# ...
# Set to string value "lf"
# This setting forces Git to normalize line endings to LF on checkin and prevents conversion to CRLF when the file is checked out.
# Git config
# When .gitattributes isn't used the core.autocrlf setting comes into play. The
# Git install wizard will present the following radio buttons during
# installation:
# - Checkout Windows-style, commit Unix-style line endings
# Git will convert LF to CRLF when checking out text files. When committing
# text files, CRLF will be converted to LF. For cross-platform projects,
# this is the recommended setting on Windows ("core.autocrlf" is set to "true").
# - Checkout as-is, commit Unix-style line endings
# Git will not perform any conversion when checking out text files. When
# committing text files, CRLF will be converted to LF. For cross-platform projects,
# this is the recommended setting on Unix ("core.autocrlf" is set to "input").
# - Checkout as-is, commit as-is
# Git will not perform any conversions when checking out or committing
# text files. Choosing this option is not recommended for cross-platform
# projects ("core.autocrlf" is set to "false").
# Legacy:
# Older Git versions didn't auto detect which files are text for checkhout so
# you needed to specify the file types for checkhout but this has been fixed.
# See:
# https://stackoverflow.com/questions/29435156/what-will-text-auto-eol-lf-in-gitattributes-do
# https://github.com/git/git/blob/master/Documentation/RelNotes/2.10.0.txt#L248
# See also:
# https://stackoverflow.com/questions/11824428/is-there-a-way-to-determine-the-line-endings-in-a-existing-git-repo
# https://stackoverflow.com/questions/7156694/git-how-to-renormalize-line-endings-in-all-files-in-all-revisions