Re: notmuch-search-toggle-order and notmuch-tree
[notmuch-archives.git] / 80 / 07cef980ec864e4c0578c0bdddfa3187bd3e20
1 Return-Path: <tomi.ollila@iki.fi>\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 BD767431FB6\r
6         for <notmuch@notmuchmail.org>; Tue, 26 Mar 2013 02:30:43 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0.644\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0.644 tagged_above=-999 required=5\r
12         tests=[URIBL_SBL=0.644] autolearn=disabled\r
13 Received: from olra.theworths.org ([127.0.0.1])\r
14         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
15         with ESMTP id wM+F+A8r+Gny for <notmuch@notmuchmail.org>;\r
16         Tue, 26 Mar 2013 02:30:43 -0700 (PDT)\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])\r
18         by olra.theworths.org (Postfix) with ESMTP id E1D84431FAF\r
19         for <notmuch@notmuchmail.org>; Tue, 26 Mar 2013 02:30:42 -0700 (PDT)\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])\r
21         by guru.guru-group.fi (Postfix) with ESMTP id DCB8A100033;\r
22         Tue, 26 Mar 2013 11:30:30 +0200 (EET)\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>\r
24 To: Jani Nikula <jani@nikula.org>, notmuch@notmuchmail.org\r
25 Subject: Re: [PATCH 1/1] devel/STYLE: information how to enable standard\r
26         pre-commit hook\r
27 In-Reply-To: <87ppymfrjg.fsf@nikula.org>\r
28 References: <1364040435-22357-1-git-send-email-tomi.ollila@iki.fi>\r
29         <87ppymfrjg.fsf@nikula.org>\r
30 User-Agent: Notmuch/0.15.2+50~g43fdda5 (http://notmuchmail.org) Emacs/24.2.1\r
31         (x86_64-unknown-linux-gnu)\r
32 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL\r
33         $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F\r
34         !)g;OY^,BjTbr)Np:%c_o'jj,Z\r
35 Date: Tue, 26 Mar 2013 11:30:30 +0200\r
36 Message-ID: <m2li9apky1.fsf@guru.guru-group.fi>\r
37 MIME-Version: 1.0\r
38 Content-Type: text/plain\r
39 X-BeenThere: notmuch@notmuchmail.org\r
40 X-Mailman-Version: 2.1.13\r
41 Precedence: list\r
42 List-Id: "Use and development of the notmuch mail system."\r
43         <notmuch.notmuchmail.org>\r
44 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
45         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
46 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
47 List-Post: <mailto:notmuch@notmuchmail.org>\r
48 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
49 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
50         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
51 X-List-Received-Date: Tue, 26 Mar 2013 09:30:43 -0000\r
52 \r
53 On Tue, Mar 26 2013, Jani Nikula <jani@nikula.org> wrote:\r
54 \r
55 > On Sat, 23 Mar 2013, Tomi Ollila <tomi.ollila@iki.fi> wrote:\r
56 >> It is easier to enable git standard pre-commit hook, when the\r
57 >> operation to do so is presented.\r
58 >> ---\r
59 >>  devel/STYLE | 5 +++--\r
60 >>  1 file changed, 3 insertions(+), 2 deletions(-)\r
61 >>\r
62 >> diff --git a/devel/STYLE b/devel/STYLE\r
63 >> index 0792ba1..92de42c 100644\r
64 >> --- a/devel/STYLE\r
65 >> +++ b/devel/STYLE\r
66 >> @@ -45,8 +45,9 @@ function (param_type param, param_type param)\r
67 >>     - likewise, there is a space following keywords such as if and while\r
68 >>     - every binary operator should have space on either side.\r
69 >>  \r
70 >> -* No trailing whitespace. Please enable the standard pre-commit hook\r
71 >> -  in git (or an equivalent hook).\r
72 >> +* No trailing whitespace. Please enable the standard pre-commit hook in git\r
73 >> +  (or an equivalent hook). The standard pre-commit hook is enabled by simply\r
74 >> +  renaming file '.git/hooks/pre-commit.sample' to '.git/hooks/pre-commit' .\r
75 >\r
76 > <bikeshedding>\r
77 >\r
78 > Or just refer to http://git-scm.com/book/en/Customizing-Git-Git-Hooks or\r
79 > man githooks if you really need to. Older versions of git used to have\r
80 > properly named hooks with the executable bit unset...\r
81 \r
82 True, older versions used different convention. I presume minority of\r
83 users have such an old version.\r
84 \r
85 Just this minor indirection will make many users skip the activation of\r
86 the hook as it requires more effort to find the information; I belong\r
87 to this group of people; I prefer super simple instructions :D\r
88 \r
89 > Personally I wouldn't ask anyone to enable the hook because I wouldn't\r
90 > enable it in the first place. There's $EDITOR and 'git diff --check' to\r
91 > do that kind of thing... When I want to commit I want to commit, warts\r
92 > and all, and I don't want a hook to prevent me from doing so!\r
93 \r
94 git commit -n (or --no-verify) will bypass the hooks. I have the hook\r
95 enabled (in fact I was surprised that it was) and I don't recall a case\r
96 when I had to resort to -n option (or edit the content to make the\r
97 commit pass the hook).\r
98 \r
99 > </bikeshedding>\r
100 \r
101 So, my point is that if there is clear-enough way to inform majority\r
102 of users how to enable hook users will do it; the hook helps users\r
103 to provide more compliant code (and, more importantantly, less review\r
104 comments about whitespace problems) andd in case there is need to bypass\r
105 the check that is also easy to do -- more documentation about bypassing\r
106 check could be added, though (I'll do it if this change get supporters...).\r
107 \r
108 >\r
109 > BR,\r
110 > Jani.\r
111 \r
112 \r
113 Tomi\r