Re: [COMMITTERS] pgsql: Run pgindent on 9.2 source tree in preparation for first 9.3
От | Noah Misch |
---|---|
Тема | Re: [COMMITTERS] pgsql: Run pgindent on 9.2 source tree in preparation for first 9.3 |
Дата | |
Msg-id | 20120616051031.GC19132@tornado.leadboat.com обсуждение исходный текст |
Ответ на | Re: [COMMITTERS] pgsql: Run pgindent on 9.2 source tree in preparation for first 9.3 (Bruce Momjian <bruce@momjian.us>) |
Ответы |
Re: [COMMITTERS] pgsql: Run pgindent on 9.2 source tree in
preparation for first 9.3
|
Список | pgsql-hackers |
On Fri, Jun 15, 2012 at 10:45:16PM -0400, Bruce Momjian wrote: > I have updated the pgindent README to use > these Perl indent instructions: > > find . -name \*.pl -o -name \*.pm | xargs perltidy \ > --backup-and-modify-in-place --opening-brace-on-new-line \ > --vertical-tightness=2 --vertical-tightness-closing=2 \ > --nospace-after-keyword=for --nospace-for-semicolon \ > --add-whitespace --delete-old-whitespace --paren-tightness=2 \ > --keep-old-blank-lines=2 --maximum-line-length=78 \ > --entab-leading-whitespace=4 --output-line-ending=unix I would lean against using --nospace-after-keyword=for. Not using it means we get wrong formatting when the for-loop conditions span multiple lines. Using it means we get wrong formatting (albeit less severe) on every for-loop. In any event, if we do use it for for-loops, we should probably use it for all control structure keywords. Otherwise, I like this. As a last idle idea, how about putting the options in a configuration file and passing --profile= as the only option? Besides keeping you from copying a 7-line shell command, this has the benefit of ignoring any ~/.perltidyrc. Thanks, nm
В списке pgsql-hackers по дате отправления: