1 Return-Path: <wking@tremily.us>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by olra.theworths.org (Postfix) with ESMTP id 85B43431FC4
\r
6 for <notmuch@notmuchmail.org>; Sun, 22 Mar 2015 15:51:52 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=2.338 tagged_above=-999 required=5
\r
12 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
\r
13 DNS_FROM_AHBL_RHSBL=2.438, RCVD_IN_DNSWL_NONE=-0.0001]
\r
15 Received: from olra.theworths.org ([127.0.0.1])
\r
16 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
17 with ESMTP id F6JAVr9Bvbcy for <notmuch@notmuchmail.org>;
\r
18 Sun, 22 Mar 2015 15:51:49 -0700 (PDT)
\r
19 Received: from resqmta-po-04v.sys.comcast.net (resqmta-po-04v.sys.comcast.net
\r
21 (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))
\r
22 (No client certificate requested)
\r
23 by olra.theworths.org (Postfix) with ESMTPS id 4053E431FBF
\r
24 for <notmuch@notmuchmail.org>; Sun, 22 Mar 2015 15:51:49 -0700 (PDT)
\r
25 Received: from resomta-po-04v.sys.comcast.net ([96.114.154.228])
\r
26 by resqmta-po-04v.sys.comcast.net with comcast
\r
27 id 6mrX1q0024vw8ds01mroCG; Sun, 22 Mar 2015 22:51:48 +0000
\r
28 Received: from odin.tremily.us ([67.168.81.176])
\r
29 by resomta-po-04v.sys.comcast.net with comcast
\r
30 id 6mrm1q00N3oF5yT01mrm4y; Sun, 22 Mar 2015 22:51:48 +0000
\r
31 Received: by odin.tremily.us (Postfix, from userid 1000)
\r
32 id C36E316DE2B7; Sun, 22 Mar 2015 15:51:45 -0700 (PDT)
\r
33 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tremily.us; s=odin;
\r
34 t=1427064705; bh=9AXyGYUCwg9cInTygObei5wz79J9BhhmTI994Ow84fk=;
\r
35 h=From:To:Cc:Subject:Date;
\r
36 b=Qx9htPQkvXf8NIZpAHDDI2cUUa2z4AhA7CIkx/GflfrFP0ZqWUl7DO1nn9STCOWLj
\r
37 PesTYSO8oEzQP+OHzP+XSyvL1hG//+W1Fdu3tLVeSRb0yD5dxKW1APagJNnyih5CiD
\r
38 x5JnZN+H4r+G91mIAfpj2ShO6S8Zc2n1GiXd7ZhU=
\r
39 From: "W. Trevor King" <wking@tremily.us>
\r
40 To: notmuch@notmuchmail.org
\r
41 Subject: [PATCH v4] nmbug-status: Use 'show-ref --heads' for loading configs
\r
42 Date: Sun, 22 Mar 2015 15:51:41 -0700
\r
44 <27b065bda7a31387f8f08069f30a2c2103ffc4e2.1427064160.git.wking@tremily.us>
\r
45 X-Mailer: git-send-email 2.0.5
\r
46 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net;
\r
47 s=q20140121; t=1427064708;
\r
48 bh=XlQLfk4tBvzkL+u9Cmu97EMOMrS52rLkr44DxJ3fV6c=;
\r
49 h=Received:Received:Received:From:To:Subject:Date:Message-Id;
\r
50 b=dA7Cu4zv78pSz6117rl2AELbwpyqGUpd1ecPspX0wF97EpOCZO+p2NkYg7FO9SzNN
\r
51 k9OofNtTRYLY0EDEnomLT/kjFNMNrOQKpkKc07Boq0Tf1qrh2AfMPK9KT4N22TBS6n
\r
52 kgx2sKmJYboo7YTnLTqKpG8R0xYi1BexxSj+1tp3rOBXVsHSnYucnHSdSqwk+ouvJB
\r
53 17DGhmb9/JyU3GLEriYVhN2nk0oNyVQJpFhU6E1ZyCe6ynM0XOa3t/pwo59c45SNlc
\r
54 ikTRPnHacVjTDqE5Llae1LAMb9gX0vmIEnShkDa/Uzl/bBt5OT9PZpNMTfsLRM4LWx
\r
56 Cc: Tomi Ollila <tomi.ollila@iki.fi>
\r
57 X-BeenThere: notmuch@notmuchmail.org
\r
58 X-Mailman-Version: 2.1.13
\r
60 List-Id: "Use and development of the notmuch mail system."
\r
61 <notmuch.notmuchmail.org>
\r
62 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
63 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
64 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
65 List-Post: <mailto:notmuch@notmuchmail.org>
\r
66 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
67 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
68 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
69 X-List-Received-Date: Sun, 22 Mar 2015 22:51:52 -0000
\r
71 When loading configs from Git, the bare branch name (without a
\r
72 refs/heads/ prefix or similar) matches all branches of that name
\r
73 (including remote-tracking branches):
\r
75 .nmbug $ git show-ref config
\r
76 48f3bbf1d1492e5f3d2f01de6ea79a30d3840f20 refs/heads/config
\r
77 48f3bbf1d1492e5f3d2f01de6ea79a30d3840f20 refs/remotes/origin/config
\r
78 4b6dbd9ffd152e7476f5101eff26747f34497cee refs/remotes/wking/config
\r
80 Instead of relying on the ordering of the matching references, use
\r
81 --heads to ensure we only match local branches.
\r
83 The only change from v3 [1] is dropping the accidental indentation
\r
84 hunk that started with '@@ -178,14 +193,14 @@ nmbug-status'. Thanks
\r
85 to Tomi for pointing this out on IRC.
\r
87 [1]: id: e9d25cc269b7bcc058627466adfa2835256b6e76.1427012574.git.wking@tremily.us
\r
88 http://thread.gmane.org/gmane.mail.notmuch.general/20356
\r
90 NEWS | 15 +++++++++++++++
\r
91 devel/nmbug/nmbug | 1 +
\r
92 devel/nmbug/nmbug-status | 2 +-
\r
93 3 files changed, 17 insertions(+), 1 deletion(-)
\r
95 diff --git a/NEWS b/NEWS
\r
96 index 70ad3f3..336a7c3 100644
\r
99 @@ -23,6 +23,21 @@ Contrib
\r
100 previously provided by `notmuch-deliver` should now be provided by
\r
101 `notmuch insert`, provided by the main notmuch binary.
\r
106 +`nmbug-status` now only matches local branches when reading
\r
107 +`status-config.json` from the `config` branch of the `NMBGIT`
\r
108 +repository. To help new users running `nmbug-status`, `nmbug clone`
\r
109 +now creates a local `config` branch tracking `origin/config`. Folks
\r
110 +who use `nmbug-status` with an in-Git config (i.e. you don't use the
\r
111 +`--config` option) who already have `NMBGIT` set up are encouraged to
\r
114 + git checkout config origin/config
\r
116 +in their `NMBGIT` repository (usually `~/.nmbug`).
\r
118 Notmuch 0.19 (2014-11-14)
\r
119 =========================
\r
121 diff --git a/devel/nmbug/nmbug b/devel/nmbug/nmbug
\r
122 index 932ec12..81f582c 100755
\r
123 --- a/devel/nmbug/nmbug
\r
124 +++ b/devel/nmbug/nmbug
\r
125 @@ -308,6 +308,7 @@ def clone(repository):
\r
127 _git(args=['config', '--unset', 'core.worktree'], wait=True)
\r
128 _git(args=['config', 'core.bare', 'true'], wait=True)
\r
129 + _git(args=['branch', 'config', 'origin/config'], wait=True)
\r
132 def _is_committed(status):
\r
133 diff --git a/devel/nmbug/nmbug-status b/devel/nmbug/nmbug-status
\r
134 index 19dc48a..e845c2a 100755
\r
135 --- a/devel/nmbug/nmbug-status
\r
136 +++ b/devel/nmbug/nmbug-status
\r
137 @@ -92,7 +92,7 @@ def read_config(path=None, encoding=None):
\r
139 # read only the first line from the pipe
\r
140 sha1_bytes = subprocess.Popen(
\r
141 - ['git', '--git-dir', nmbhome, 'show-ref', '-s', branch],
\r
142 + ['git', '--git-dir', nmbhome, 'show-ref', '-s', '--heads', branch],
\r
143 stdout=subprocess.PIPE).stdout.readline()
\r
144 sha1 = sha1_bytes.decode(encoding).rstrip()
\r