Re: run pgindent on a regular basis / scripted manner - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: run pgindent on a regular basis / scripted manner
Date
Msg-id b8f18576-afc0-d961-b33b-c0fa2e63edeb@dunslane.net
Whole thread Raw
In response to Re: run pgindent on a regular basis / scripted manner  (Jelte Fennema <postgres@jeltef.nl>)
Responses Re: run pgindent on a regular basis / scripted manner
List pgsql-hackers


On 2023-02-07 Tu 12:21, Jelte Fennema wrote:
On Mon, Feb 6, 2023 at 10:21 AM Andrew Dunstan <andrew@dunslane.net> wrote:

Here's a quick patch for 1 and 3. Would also need to adjust the docco.



This time with patch.
When supplying the --commit flag it still formats all files for me. I
was able to fix that by replacing:
# no non-option arguments given. so do everything in the current directory
$code_base ||= '.' unless @ARGV;

with:
# no files, dirs or commits given. so do everything in the current directory
$code_base ||= '.' unless @ARGV || @commits;


Yeah, thanks for testing. Here's a new patch with that change and the comment adjusted.



Does the code-base flag still make sense if you can simply pass a
directory as regular args now?


Probably not. I'll look into removing it.


cheers


andrew

--
Andrew Dunstan
EDB: https://www.enterprisedb.com
Attachment

pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: OpenSSL 3.0.0 vs old branches
Next
From: Aleksander Alekseev
Date:
Subject: Re: [PATCH] Make ON CONFLICT DO NOTHING and ON CONFLICT DO UPDATE consistent