public inbox for libc-hacker@sourceware.org
 help / color / mirror / Atom feed
From: Jim Meyering <jim@meyering.net>
To: Ulrich Drepper <drepper@redhat.com>
Cc: GNU libc hacker <libc-hacker@sources.redhat.com>
Subject: Re: git whitespace test
Date: Mon, 15 Jun 2009 16:06:00 -0000	[thread overview]
Message-ID: <87k53djxbc.fsf@meyering.net> (raw)
In-Reply-To: <4A366FBD.3060803@redhat.com> (Ulrich Drepper's message of "Mon, 15 Jun 2009 08:58:53 -0700")

Ulrich Drepper wrote:
> I had to set
>
>   hooks.allowbadwhitespace
>
> in glibc's git to true.  The timezone data files have trailing
> whitespaces and I don't want to make these unnecessary changes which
> just make tracking upstream harder.  We lived in cvs days without this.
>  Every file I edit gets automatically fixed anyway.

How about an alternative: use a .gitattributes file to exempt just
those files.  Then we can turn the global hook back on, and relax
policy as needed by modifying .gitattributes.

Here's a proposed patch.

From b92e815818d1389c45174e34527063723e291a95 Mon Sep 17 00:00:00 2001
From: Jim Meyering <meyering@redhat.com>
Date: Mon, 15 Jun 2009 18:03:56 +0200
Subject: [PATCH] exempt timezone files from the no-bad-whitespace policy

* .gitattributes: New file.  Exempt imported timezone files from
the no-bad-whitespace rules.
---
 .gitattributes |    1 +
 ChangeLog      |    6 ++++++
 2 files changed, 7 insertions(+), 0 deletions(-)
 create mode 100644 .gitattributes

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..8947e72
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1 @@
+timezone/* -whitespace
diff --git a/ChangeLog b/ChangeLog
index dcd7444..ac37750 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-06-15  Jim Meyering  <meyering@redhat.com>
+
+	exempt timezone files from the no-bad-whitespace policy
+	* .gitattributes: New file.  Exempt imported timezone files from
+	the no-bad-whitespace rules.
+
 2009-06-15  Ulrich Drepper  <drepper@redhat.com>

 	* timezone/tzselect.ksh: Update from tzcode2009i.
--
1.6.3.2.406.gd6a466

  reply	other threads:[~2009-06-15 16:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-15 15:59 Ulrich Drepper
2009-06-15 16:06 ` Jim Meyering [this message]
2009-06-15 16:16   ` Ulrich Drepper
2009-06-15 16:19     ` Jim Meyering

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k53djxbc.fsf@meyering.net \
    --to=jim@meyering.net \
    --cc=drepper@redhat.com \
    --cc=libc-hacker@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).