Search notes:

.gitattributes

*.cpp      eol=lf
*.png      binary

linguist

linguist-… provides a way for custom override stategies for language definitions and file paths.

linguist-language

linguist-language identify/override the assumed language depending on the extension (for example by GitHub which uses the linguist library to identify languages in a repository).
For example, the following three lines make sure that *.bas, *.cls and *.frm are counted as Visual Basic for Application (VBA) source code:
*.bas linguist-language=vba
*.cls linguist-language=vba
*.frm linguist-language=vba

Links

This Github repository claims to collect useful .gitattribute templates.

Index