.GITATTRIBUTES File Extension
Git Attributes File
4.1 | 15 Votes
What is a GITATTRIBUTES file?
Path-specific setting file used by Git, a version control system used for storing source code; contains attributes that dictate what settings Git applies to certain subdirectories or subsets of files; located in the root directory of the project; similar to the .GITIGNORE file.
The GITATTRIBUTES file enables you to perform a variety of functions such as commanding Git how it should diff (show changes between an index and a tree, changes between two trees, etc.) non-text files or having Git filter content before checking it into or out of Git.
A helpful attribute that will tell Git to treat a specific file extension as binary data:
*.extension -crlf -diff or *.extension binary
Here is an example of a GITATTRIBUTES file:
# Auto detect text files and perform LF normalization
# Custom for Visual Studio
# Standard to msysgit