Re: cfbot run pgindent?

From: Thomas Munro <thomas(dot)munro(at)enterprisedb(dot)com>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: Robbie Harwood <rharwood(at)redhat(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: cfbot run pgindent?
Date: 2018-12-19 01:12:28
Message-ID: CAEepm=1D4_wypsYgfZgK-vPx04FJgDx53PG9KXsA+WWG6MrGpA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Dec 19, 2018 at 8:08 AM Peter Eisentraut
<peter(dot)eisentraut(at)2ndquadrant(dot)com> wrote:
> On 18/12/2018 19:50, Robbie Harwood wrote:
> > Second, since the project does have a defined style checker, do you
> > think it would be possible to run it as part of cfbot and report errors?
>
> pgindent is a code formatter, not a style checker. Using it to check
> whether just the newly added code is correctly formatted would probably
> require that all existing code is correctly formatted at all times,
> which isn't the case.
>
> What cfbot could do is spit out a diff at the end between the current
> code and the pgindent'ed version. That might be useful in some cases.

pgindent has the problem of that typename list that is maintained by
mysterious manual means, so it might be noisy.

I think that in general any extra checks (for example perl scripts
that check that nodes have all the right boilerplate, read/write
functions etc, wait points have names and documentation, ... etc as
discussed a while back) might as well be in-tree and runnable from the
makefile so that everyone can run them directly if they want, and then
cfbot could too.

--
Thomas Munro
http://www.enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2018-12-19 01:13:08 Use an enum for RELKIND_*?
Previous Message Michael Paquier 2018-12-19 01:11:54 Re: cfbot run pgindent?