Re: Add pgindent test to check if codebase is correctly formatted

From: "Tristan Partin" <tristan(at)neon(dot)tech>
To: "Alvaro Herrera" <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: "pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org>, "Jelte Fennema-Nio" <postgres(at)jeltef(dot)nl>
Subject: Re: Add pgindent test to check if codebase is correctly formatted
Date: 2024-01-17 16:15:38
Message-ID: CYH46EOI1L9I.2CBHTXWCEI65Y@neon.tech
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed Jan 17, 2024 at 3:50 AM CST, Alvaro Herrera wrote:
> Hmm, should this also install typedefs.list and pgindent.man?
> What about the tooling to reformat Perl code?

Good point about pgindent.man. It would definitely be good to install
alongside pgindent and pg_bsd_indent.

I don't know if we need to install the typedefs.list file. I think it
would just be good enough to also install the find_typedefs script. But
it needs some fixing up first[0]. Extension authors can then just
generate their own typedefs.list that will include the typedefs of the
extension and the typedefs of the postgres types they use. At least,
that is what we have found works at Neon.

I cannot vouch for extension authors writing Perl but I think it could
make sense to install the src/test/perl tree, so extension authors could
more easily write tests for their extensions in Perl. But we could
install the perltidy file and whatever else too. I keep my Perl writing
to a minimum, so I am not the best person to vouch for these usecases.

[0]: https://www.postgresql.org/message-id/aaa59ef5-dce8-7369-5cae-487727664127%40dunslane.net

--
Tristan Partin
Neon (https://neon.tech)

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2024-01-17 16:15:53 Re: initdb's -c option behaves wrong way?
Previous Message cca5507 2024-01-17 15:57:21 [pg16]Question about building snapshot in logical decoding