Re: Formatting Curmudgeons WAS: MMAP Buffers
Greg Smith <greg@2ndquadrant.com>
From: Greg Smith <greg@2ndquadrant.com>
To: Andrew Dunstan <andrew@dunslane.net>
Cc: Jeff Janes <jeff.janes@gmail.com>, Christopher Browne <cbbrowne@gmail.com>, PG Hackers <pgsql-hackers@postgresql.org>
Date: 2011-04-18T04:48:06Z
Lists: pgsql-hackers
Andrew Dunstan wrote: > Now we could certainly make this quite a bit slicker. Apart from > anything else, we should change the indent source code tarball so it > unpacks into its own directory. Having it unpack into the current > directory is ugly and unfriendly. And we should get rid of the "make > clean" line in the install target of entab's makefile, which just > seems totally ill-conceived. I think the script I submitted upthread has most of the additional slickness needed here. Looks like we both were working on documenting a reasonable way to do this at the same time the other day. The idea of any program here relying on being able to write to /usr/local/bin as your example did makes this harder for people to run; that's why I made everything in the build tree and just pushed the appropriate directories into the PATH. Since I see providing a script to automate this whole thing as the preferred way to make this easier, re-packaging the indent source tarball to extract to a directory doesn't seem worth the backwards compatibility trouble it will introduce. Improving the entab makefile I don't have an opinion on. > It might also be worth setting it up so that instead of having to pass > a path to a typedefs file on the command line, we default to a file > sitting in, say, /usr/local/etc. Then you'd just be able to say > "pgindent my_file.c". OK, so I need to update my script to handle either indenting a single file, or doing all of them. -- Greg Smith 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD PostgreSQL Training, Services, and 24x7 Support www.2ndQuadrant.us