From dd79324d7a821b671f3cf3c76c95ebfe2335e83a Mon Sep 17 00:00:00 2001 From: Frederic Pillon Date: Tue, 31 Mar 2020 12:22:32 +0200 Subject: [PATCH 1/4] Force LF line ending Signed-off-by: Frederic Pillon --- .gitattributes | 47 +++++++++++++++++++++++++++++++++++------------ 1 file changed, 35 insertions(+), 12 deletions(-) diff --git a/.gitattributes b/.gitattributes index 86f6b3b50b..1283f63835 100644 --- a/.gitattributes +++ b/.gitattributes @@ -3,18 +3,41 @@ # Explicitly declare text files you want to always be normalized and converted # to native line endings on checkout. -*.c text -*.cpp text -*.h text -*.s text -*.S text -*.ld text -*.txt text -*.xml text -*.py text -*.md text -*.json text +.astyleignore text eol=lf +.astylerc text eol=lf +.editorconfig text eol=lf +.flake8 text eol=lf +.gitattributes text eol=lf +.gitignore text eol=lf + +*.adoc text eol=lf +*.c text eol=lf +*.cmake text eol=lf +*.cpp text eol=lf +*.css text eol=lf +*.dtsi text eol=lf +*.gv text eol=lf +*.h text eol=lf +*.html text eol=lf +*.in text eol=lf +*.ino text eol=lf +*.json text eol=lf +*.ld text eol=lf +*.md text eol=lf +*.MD text eol=lf +*.old text eol=lf +*.pde text eol=lf +*.properties text eol=lf +*.py text eol=lf +*.s text eol=lf +*.S text eol=lf +*.sh text eol=lf +*.spec text eol=lf +*.txt text eol=lf +*.yml text eol=lf # Denote all files that are truly binary and should not be modified. -*.png binary *.jpg binary +*.pdf binary +*.png binary + From 9355bc09a613d0fd990dd73a7b49e3c2219dc59e Mon Sep 17 00:00:00 2001 From: Frederic Pillon Date: Tue, 31 Mar 2020 15:04:18 +0200 Subject: [PATCH 2/4] [Astyle] Force LF line ending Signed-off-by: Frederic Pillon --- CI/astyle/.astylerc | 1 + 1 file changed, 1 insertion(+) diff --git a/CI/astyle/.astylerc b/CI/astyle/.astylerc index f92622a908..a64f33c366 100644 --- a/CI/astyle/.astylerc +++ b/CI/astyle/.astylerc @@ -13,6 +13,7 @@ style=kr # 2 spaces, convert tabs to spaces indent=spaces=2 convert-tabs +lineend=linux # Indent switches and cases indent-classes From c4ab08a781371f33675136449542034467419c54 Mon Sep 17 00:00:00 2001 From: Frederic Pillon Date: Tue, 31 Mar 2020 15:16:30 +0200 Subject: [PATCH 3/4] [.editorconfig] Force LF line ending Signed-off-by: Frederic Pillon --- .editorconfig | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.editorconfig b/.editorconfig index a35d225886..36e4f7bc69 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,3 +1,7 @@ +[*] +end_of_line = lf +insert_final_newline = true + [*.sh] # like -i=2 indent_style = space From 30ca0e1ab7b1bf3485a42941e25d7db72bc59b1d Mon Sep 17 00:00:00 2001 From: Frederic Pillon Date: Tue, 31 Mar 2020 15:25:00 +0200 Subject: [PATCH 4/4] [.editorconfig] Add rules to match Astyle rules Signed-off-by: Frederic Pillon --- .editorconfig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.editorconfig b/.editorconfig index 36e4f7bc69..c9b76fd638 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,6 +1,9 @@ [*] end_of_line = lf insert_final_newline = true +indent_style = space +indent_size = 2 +trim_trailing_whitespace = true [*.sh] # like -i=2