diff mbox series

[ovs-dev,v2] build: Add gitattribute file to build-aux

Message ID 20180719163942.8500-1-aserdean@ovn.org
State Accepted
Headers show
Series [ovs-dev,v2] build: Add gitattribute file to build-aux | expand

Commit Message

Alin-Gabriel Serdean July 19, 2018, 4:39 p.m. UTC
The command: `make check-tabs` fails on Windows due to line ending conversions
caused by the following setting: `git config --global core.autocrlf true`
(the whitelist `build-aux/initial-tab-whitelist` becomes a blacklist)

This patch adds a .gittatribute file to build-aux to force LF endings
on Windows.

Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
Co-authored-by: Aaron Conole <aconole@redhat.com>
---
v2: fold in changes Suggested-by: Aaron Conole <aconole@redhat.com>
---
 .gitignore               | 1 -
 Makefile.am              | 1 +
 build-aux/.gitattributes | 1 +
 3 files changed, 2 insertions(+), 1 deletion(-)
 create mode 100644 build-aux/.gitattributes

Comments

0-day Robot July 19, 2018, 4:56 p.m. UTC | #1
Bleep bloop.  Greetings Alin Gabriel Serdean, I am a robot and I have tried out your patch.
Thanks for your contribution.

I encountered some error that I wasn't expecting.  See the details below.


checkpatch:
ERROR: Too many signoffs; are you missing Co-authored-by lines?
ERROR: Co-authored-by/Signed-off-by corruption
Lines checked: 56, Warnings: 0, Errors: 2


Please check this out.  If you feel there has been an error, please email aconole@bytheb.org

Thanks,
0-day Robot
Aaron Conole July 19, 2018, 5:03 p.m. UTC | #2
Alin Gabriel Serdean <aserdean@ovn.org> writes:

> The command: `make check-tabs` fails on Windows due to line ending conversions
> caused by the following setting: `git config --global core.autocrlf true`
> (the whitelist `build-aux/initial-tab-whitelist` becomes a blacklist)
>
> This patch adds a .gittatribute file to build-aux to force LF endings
> on Windows.
>
> Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
> Co-authored-by: Aaron Conole <aconole@redhat.com>
> ---

Signed-off-by: Aaron Conole <aconole@redhat.com>

Thanks, Alin!
Ben Pfaff July 19, 2018, 5:42 p.m. UTC | #3
On Thu, Jul 19, 2018 at 07:39:42PM +0300, Alin Gabriel Serdean wrote:
> The command: `make check-tabs` fails on Windows due to line ending conversions
> caused by the following setting: `git config --global core.autocrlf true`
> (the whitelist `build-aux/initial-tab-whitelist` becomes a blacklist)
> 
> This patch adds a .gittatribute file to build-aux to force LF endings
> on Windows.
> 
> Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
> Co-authored-by: Aaron Conole <aconole@redhat.com>
> ---
> v2: fold in changes Suggested-by: Aaron Conole <aconole@redhat.com>

I guess you should wait for a Signed-off-by from Aaron, but as long as
you get it:

Acked-by: Ben Pfaff <blp@ovn.org>
Alin-Gabriel Serdean July 19, 2018, 6:09 p.m. UTC | #4
> On 19 Jul 2018, at 20:42, Ben Pfaff <blp@ovn.org> wrote:
> 
> On Thu, Jul 19, 2018 at 07:39:42PM +0300, Alin Gabriel Serdean wrote:
>> The command: `make check-tabs` fails on Windows due to line ending conversions
>> caused by the following setting: `git config --global core.autocrlf true`
>> (the whitelist `build-aux/initial-tab-whitelist` becomes a blacklist)
>> 
>> This patch adds a .gittatribute file to build-aux to force LF endings
>> on Windows.
>> 
>> Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
>> Co-authored-by: Aaron Conole <aconole@redhat.com>
>> ---
>> v2: fold in changes Suggested-by: Aaron Conole <aconole@redhat.com>
> 
> I guess you should wait for a Signed-off-by from Aaron, but as long as
> you get it:
> 
> Acked-by: Ben Pfaff <blp@ovn.org>

Thanks Aaron and Ben! I applied it on master.
diff mbox series

Patch

diff --git a/.gitignore b/.gitignore
index 81faf270d..60e7818c3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -31,7 +31,6 @@ 
 .libs
 .tmp_versions
 .vagrant
-.gitattributes
 /Makefile
 /Makefile.in
 /aclocal.m4
diff --git a/Makefile.am b/Makefile.am
index e02799a90..fd6620a9b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -199,6 +199,7 @@  dist-hook-git: distfiles
 	  (cat distfiles; sed 's|^|datapath/|' datapath/distfiles) | \
 	    LC_ALL=C sort -u > all-distfiles; \
 	  (cd $(srcdir) && git ls-files) | grep -v '\.gitignore$$' | \
+	    grep -v '\.gitattributes$$' | \
 	    LC_ALL=C sort -u > all-gitfiles; \
 	  LC_ALL=C comm -1 -3 all-distfiles all-gitfiles > missing-distfiles; \
 	  if test -s missing-distfiles; then \
diff --git a/build-aux/.gitattributes b/build-aux/.gitattributes
new file mode 100644
index 000000000..fcadb2cf9
--- /dev/null
+++ b/build-aux/.gitattributes
@@ -0,0 +1 @@ 
+* text eol=lf