From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Generating config stuff from single source |
Date: | 2006-02-16 11:30:43 |
Message-ID: | 20060216113043.GA26127@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, Feb 16, 2006 at 02:36:01AM +0100, Peter Eisentraut wrote:
> We are currently maintaining information about configuration parameters
> in at least three places: the documentation, guc.c, and
> postgresql.conf.sample. I would like to generate these from a single
> source. Computationally, this is not very challenging, it's just a bit
> of work. I imagine as the source an XML file with a custom schema; see
> below for an example. I think this is the best source format because
> it allows integrating the DocBook-formatted descriptions without too
> much trouble and it allows for file format validation. An alternative
> might be m4 but that would not offer these features. To process this
> we'd use XSLT stylesheets run through xsltproc. We'd run this part
> during the tarball building phase, so users would not need it.
> Obviously, all of this will need some fine-tuning, but can we agree on
> this general direction?
Is there any reason why we can't just use something like awk? It's
installed almost everywhere (it may be required, not sure) and a lot
more people know how to use it. I havn't managed to wrap my brain
around xslt yet.
The input file could be simply line based. Attached is a simple script
that takes the input below and produces something resembling what you
suggested. It wouldn't be too hard to get it to produce multiple output
formats and dump the output to different files...
----
Group: Query Tuning
Subgroup: Planner Method Configuration
Name: enable_hashagg
Context: userset
... etc ...
----
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.
Attachment | Content-Type | Size |
---|---|---|
test.awk | text/plain | 1.3 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Steinar H. Gunderson | 2006-02-16 11:35:22 | Re: qsort again (was Re: Strange Create Index |
Previous Message | Gary Doades | 2006-02-16 11:06:32 | Re: [HACKERS] qsort again (was Re: Strange Create Index |