Re: pgindent vs dtrace on macos
Daniel Gustafsson <daniel@yesql.se>
From: Daniel Gustafsson <daniel@yesql.se>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2020-09-17T08:15:30Z
Lists: pgsql-hackers
>>> The attached patch fixes the generation of sql_help.h and perl_opmask.h to make >>> sure they conform to pgindent. Those were the only file I got diffs in after a >>> pgindent run apart from fmgrprotos.h which gave the below: > >> Hmm, I seem to recall there were more when this happened to me back in >> May. But in any case, fixing these is an improvement. > > Experimenting with this patch soon found one additional case: sql_help.c, > also emitted by create_help.pl, also needs some whitespace help. > I do not recall if there are other places, but fixing these is > surely a step forward. I fixed the sql_help.c output and pushed it. Thanks! I think a bug for .c and .h files with matching names in my small script testing for discrepancies hid that one. >> On that note, I >> wonder if we should add the plperl .xs generated files as exclusions too since >> we don't control that generator? > > Not an issue I don't think; pgindent won't touch extensions other than > .c and .h. Sorry for being unclear, I meant the generated .c counterpart of the .xs file. So something like the below: --- a/src/tools/pgindent/exclude_file_patterns +++ b/src/tools/pgindent/exclude_file_patterns @@ -5,6 +5,8 @@ /ecpg/test/expected/ /snowball/libstemmer/ /pl/plperl/ppport\.h$ +/pl/plperl/SPI\.c$ +/pl/plperl/Util\.c$ /jit/llvmjit\.h$ /utils/probes\.h$ /tmp_check/ cheers ./daniel
Commits
-
Exclude fmgrprotos.h from pgindent processing.
- c4133ec169df 14.0 landed
-
Fix a few more generator scripts to produce pgindent-clean output.
- f859c2ffa01d 14.0 landed
-
Further improve pgindent's list of file exclusions.
- 74d4608f506b 14.0 landed
-
Improve formatting of create_help.pl and plperl_opmask.pl output.
- add105840b67 14.0 landed