git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Karl Hasselström" <kha@treskal.com>
To: Catalin Marinas <catalin.marinas@gmail.com>
Cc: Daniel Aarno <aarno@virtutech.com>, git@vger.kernel.org
Subject: [PATCH] Pass "git config" flags in the right order
Date: Fri, 29 May 2009 09:43:50 +0200	[thread overview]
Message-ID: <20090529074300.20591.96310.stgit@october.hq.vtech> (raw)

From: Karl Hasselström <kha@treskal.com>

New enough gits accept the --null and --list flags in any order, but
older gits want --null before --list. So do it the way that's fine
with everyone.

I think (but haven't verified) that git started to accept the flags in
any order after commit d64ec16c2af4ddcf3985d11d5dc28a15db181de5 ("git
config: reorganize to use parseopt") by Felipe Contreras on
2009-02-21, first released in git v1.6.3.

Signed-off-by: Karl Hasselström <kha@treskal.com>

---

Bug discovered by Daniel Aarno.

 stgit/config.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/stgit/config.py b/stgit/config.py
index c40756c..dc9c9eb 100644
--- a/stgit/config.py
+++ b/stgit/config.py
@@ -48,7 +48,7 @@ class GitConfig:
         if self.__cache is not None:
             return
         self.__cache = {}
-        lines = Run('git', 'config', '--list', '--null').raw_output()
+        lines = Run('git', 'config', '--null', '--list').raw_output()
         for line in filter(None, lines.split('\0')):
             key, value = line.split('\n', 1)
             self.__cache.setdefault(key, []).append(value)

                 reply	other threads:[~2009-05-29  7:44 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20090529074300.20591.96310.stgit@october.hq.vtech \
    --to=kha@treskal.com \
    --cc=aarno@virtutech.com \
    --cc=catalin.marinas@gmail.com \
    --cc=git@vger.kernel.org \
    /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 NNTP newsgroup(s).