From: | Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
Cc: | David Fetter <david(at)fetter(dot)org>, PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: [PATCH] Trim trailing whitespace in vim and emacs |
Date: | 2018-06-05 20:18:05 |
Message-ID: | ae578248-80ec-923d-5836-8471f1b8b8af@2ndquadrant.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 6/5/18 13:37, Tom Lane wrote:
> I note that Peter E. seems to have a recipe for finding such issues,
> which I suspect is grounded in some obscure git feature or other.
> That might be easier to work with, since you'd only need one fix
> not one per editor.
I have a git alias:
check-whitespace = !git diff-tree --check $(git hash-object -t tree
/dev/null) HEAD ${1:-$GIT_PREFIX}
Also, in Emacs I use
(global-whitespace-mode 1)
(setq whitespace-style
'(face
trailing empty indentation space-after-tab space-before-tab))
With source code other than PostgreSQL, this will occasionally result in
angry fruit salad.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Christophe Pettus | 2018-06-05 20:22:39 | Re: Code of Conduct plan |
Previous Message | Andres Freund | 2018-06-05 20:17:42 | Re: Code of Conduct plan |