Re: run pgindent on a regular basis / scripted manner

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andres Freund <andres(at)anarazel(dot)de>, Jelte Fennema <postgres(at)jeltef(dot)nl>, Peter Geoghegan <pg(at)bowt(dot)ie>, Bruce Momjian <bruce(at)momjian(dot)us>, Magnus Hagander <magnus(at)hagander(dot)net>, Stephen Frost <sfrost(at)snowman(dot)net>, Noah Misch <noah(at)leadboat(dot)com>, Jesse Zhang <sbjesse(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: run pgindent on a regular basis / scripted manner
Date: 2023-01-23 17:38:20
Message-ID: 20230123173820.5taw5j5axceifsdz@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2023-Jan-23, Tom Lane wrote:

> 1. [...] So now I think that we should
> stick to the convention that it's on the user to install
> pg_bsd_indent somewhere in their PATH; all we'll be doing with
> this change is eliminating the step of fetching pg_bsd_indent's
> source files from somewhere else.

+1

> 2. Given #1, it'll be prudent to continue having pgindent
> double-check that pg_bsd_indent reports a specific version
> number. We could imagine starting to use the main Postgres
> version number for that, but I'm inclined to continue with
> its existing numbering series.

+1

> 3. If we do nothing special, the first mass reindentation is
> going to reformat the pg_bsd_indent sources per PG style,
> which is ... er ... not the way they look now. Do we want
> to accept that outcome, or take steps to prevent pgindent
> from processing pg_bsd_indent? I have a feeling that manual
> cleanup would be necessary if we let such reindentation
> happen, but I haven't experimented.

Hmm, initially it must just be easier to have an exception so that
pg_bsd_indent itself isn't indented.

--
Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/
#error "Operator lives in the wrong universe"
("Use of cookies in real-time system development", M. Gleixner, M. Mc Guire)

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2023-01-23 17:39:50 Re: Non-superuser subscription owners
Previous Message gkokolatos 2023-01-23 17:31:55 Re: Add LZ4 compression in pg_dump