Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 31269431E64 for ; Sun, 29 Jan 2012 23:59:30 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id N9OMTtpT0Y1X for ; Sun, 29 Jan 2012 23:59:29 -0800 (PST) Received: from guru.guru-group.fi (guru-group.fi [87.108.86.66]) by olra.theworths.org (Postfix) with ESMTP id 8E0D3431FBC for ; Sun, 29 Jan 2012 23:59:29 -0800 (PST) Received: by guru.guru-group.fi (Postfix, from userid 501) id 8839E68056; Mon, 30 Jan 2012 09:59:32 +0200 (EET) From: Tomi Ollila To: Pieter Praet , David Bremner , David Edmondson , Jani Nikula Subject: Re: [PATCH] emacs: globally replace non-branching "(if COND (progn ..." with "(when ..." In-Reply-To: <8739ax7jts.fsf@praet.org> References: <87k44uprvy.fsf@praet.org> <1326532638-22068-1-git-send-email-pieter@praet.org> <87y5ssxam7.fsf@zancas.localnet> <8739ax7jts.fsf@praet.org> User-Agent: Notmuch/0.11+116~g34d80c9 (http://notmuchmail.org) Emacs/23.3.1 (x86_64-unknown-linux-gnu) X-Face: HhBM'cA~ MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Notmuch Mail X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Jan 2012 07:59:30 -0000 On Mon, 30 Jan 2012 08:03:59 +0100, Pieter Praet wrote: > On Sat, 28 Jan 2012 08:41:36 -0400, David Bremner wrote: > > On Sat, 14 Jan 2012 10:17:18 +0100, Pieter Praet wrote: > > > Less code, same results, without sacrificing readability. > > > > > > > This looks OK, although the re-indenting makes these kind of changes > > painful to review (not that I'm suggesting we should re-indent, just > > some random complaining). > > > > You can use `diff-refine-hunk' to see what the actual changes are. > > Try this: > > #+begin_src emacs-lisp > (global-set-key (kbd "C-c /") > (lambda() > "Refine display of unified diff hunks" > (interactive) > (save-excursion > (goto-char (point-min)) > (while (re-search-forward > diff-hunk-header-re-unified > nil t) > (diff-refine-hunk))))) > #+end_src > > Work pretty much *anywhere*. > > Note: it does NOT work in `notmuch-show-mode' (not even with > `notmuch-wash-convert-inline-patch-to-part' disabled), but this is > easily solved by first running `notmuch-show-view-raw-message' ("V") > and `diff-mode' (to fontify the buffer)... What we need is 'notmuch-devel' minor mode which can do this, dme's notmuch patching tool, nmbug tag changes and everything... > > > d > > > Peace > > -- > Pieter Tomi