Re: CI: Add task that runs pgindent - Mailing list pgsql-hackers

From Nazir Bilal Yavuz
Subject Re: CI: Add task that runs pgindent
Date
Msg-id CAN55FZ1htZTESmDZu4VFek-zz1Z09j4swdHX_Z2V1zLau26W5g@mail.gmail.com
Whole thread Raw
In response to Re: CI: Add task that runs pgindent  (Daniel Gustafsson <daniel@yesql.se>)
List pgsql-hackers
Hi,

On Tue, 21 Oct 2025 at 16:46, Daniel Gustafsson <daniel@yesql.se> wrote:
>
> > On 21 Oct 2025, at 15:39, Florents Tselai <florents.tselai@gmail.com> wrote:
> >
> > That wouldn’t preclude having a CI task as well, of course.
> > The hook would mainly help contributors catch formatting issues locally, while the CI task would serve as a
failsafefor committers. 
>
> One common argument against enforcing proper indentation in submissions is that
> it adds a barrier to entry,

I think this patch targets two type of people, those who know how to run CI but:

1- Do not know how to run indentation checks
2- Forgot to run indentation checks

For #1, perhaps we could print a note suggesting people check
"src/tools/pgindent/README" when formatting fails. This might help
lower the barrier. Though it is possible it could raise it instead, I
am not entirely sure.

For #2, I think this patch is clearly helpful. We can discuss if it is
worth it to spend CI credits, though.

--
Regards,
Nazir Bilal Yavuz
Microsoft



pgsql-hackers by date:

Previous
From: Dimitrios Apostolou
Date:
Subject: Re: [PATCH v4] parallel pg_restore: avoid disk seeks when jumping short distance forward
Next
From: "Aya Iwata (Fujitsu)"
Date:
Subject: RE: [PROPOSAL] Termination of Background Workers for ALTER/DROP DATABASE