From: | Andrew Dunstan <andrew(at)dunslane(dot)net> |
---|---|
To: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Bruce Momjian <bruce(at)momjian(dot)us> |
Subject: | pgindent cleanup |
Date: | 2010-04-03 15:48:32 |
Message-ID: | 4BB76350.6090404@dunslane.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Following up Tom's complaint about behaviour of pgindent, I have been
wrestling with it a bit. I noticed several things.
First awk on my box spits out fairly useless warnings about regular
expressions containing a literal '\*'. These warnings are silenced by
replacing those with '[*]', which should have the same effect.
Second, the script issues warnings about how somebody hopes that I
installed indent.bsd.patch. Yes I did, and the messages are just
annoying noise, so I propose to get rid of them. The usual rule of unix
utilities is to be silent on success, and I think we should follow it.
Third, as mentioned in that other thread I think we should put the
exclusion of certain typedef symbols into the pgindent script.
The attached patch does all three of these things.
I'm not done yet - I am seeing issues with at least two files:
contrib/fuzzystrmatch/dmetaphone.c and
src/backend/tsearch/wparser_def.c, that I need to chase down.
Ideally, this hodegpodge of awk and sed pipes would be replaced by a
perl script that would do all that inline much more efficiently, along
with some more features. But that's a longer term project.
cheers
andrew
Attachment | Content-Type | Size |
---|---|---|
pgindent.patch | text/x-patch | 1.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Boszormenyi Zoltan | 2010-04-03 16:22:39 | ECPG doesn't delete its output file in case of an error |
Previous Message | Andrew Dunstan | 2010-04-03 15:20:45 | Re: Proposal: Add JSON support |