From 2f07a987bfd7db34546e32ca0137e2ca7797d32c Mon Sep 17 00:00:00 2001 From: Vasily Date: Sat, 2 Feb 2019 16:34:08 +0100 Subject: [PATCH] Add .gitattributes file .svg files were not treated as binary which means they were spamming up the diff log. Bash files were not being pulled with LF line endings, which means they couldn't be run by Windows Subsystem for Linux. Bash files were renamed .sh to easily allow them to be recognized by both .gitattributes and humans. Taken from https://github.com/alexkaratarakis/gitattributes. --- .gitattributes | 95 +++++++++++++++++++ build_scripts/linux/{format => format.sh} | 0 ...verify_formatting => verify_formatting.sh} | 0 3 files changed, 95 insertions(+) create mode 100644 .gitattributes rename build_scripts/linux/{format => format.sh} (100%) mode change 100755 => 100644 rename build_scripts/linux/{verify_formatting => verify_formatting.sh} (100%) mode change 100755 => 100644 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..2c1b613 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,95 @@ +# Common settings that generally should always be used with your language specific settings + +# Auto detect text files and perform LF normalization +# http://davidlaing.com/2012/09/19/customise-your-gitattributes-to-become-a-git-ninja/ +* text=auto + +# +# The above will handle all files NOT found below +# + +# Documents +*.doc diff=astextplain +*.DOC diff=astextplain +*.docx diff=astextplain +*.DOCX diff=astextplain +*.dot diff=astextplain +*.DOT diff=astextplain +*.pdf diff=astextplain +*.PDF diff=astextplain +*.rtf diff=astextplain +*.RTF diff=astextplain +*.md text +*.tex text +*.adoc text +*.textile text +*.mustache text +*.csv text +*.tab text +*.tsv text +*.sql text + +# Graphics +*.png binary +*.jpg binary +*.jpeg binary +*.gif binary +*.tif binary +*.tiff binary +*.ico binary +# SVG treated as an asset (binary) by default. If you want to treat it as text, +# comment-out the following line and uncomment the line after. +*.svg binary +#*.svg text +*.eps binary + +# +# Exclude files from exporting +# + +.gitattributes export-ignore +.gitignore export-ignore + +#sources +*.c text diff=cpp +*.cc text diff=cpp +*.cxx text diff=cpp +*.cpp text diff=cpp +*.c++ text diff=cpp +*.hpp text diff=cpp +*.h text diff=cpp +*.h++ text diff=cpp +*.hh text diff=cpp + +# Compiled Object files +*.slo binary +*.lo binary +*.o binary +*.obj binary + +# Precompiled Headers +*.gch binary +*.pch binary + +# Compiled Dynamic libraries +*.so binary +*.dylib binary +*.dll binary + +# Compiled Static libraries +*.lai binary +*.la binary +*.a binary +*.lib binary + +# Executables +*.exe binary +*.out binary +*.app binary + +#Qt Specific +*.qml text + +#Linux Shell Scripts +#Windows Subsystem for Linux will not run CLRF files. +*.sh text eof=lf diff --git a/build_scripts/linux/format b/build_scripts/linux/format.sh old mode 100755 new mode 100644 similarity index 100% rename from build_scripts/linux/format rename to build_scripts/linux/format.sh diff --git a/build_scripts/linux/verify_formatting b/build_scripts/linux/verify_formatting.sh old mode 100755 new mode 100644 similarity index 100% rename from build_scripts/linux/verify_formatting rename to build_scripts/linux/verify_formatting.sh