[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
new command to manipulate texinfo files?
From: |
Patrice Dumas |
Subject: |
new command to manipulate texinfo files? |
Date: |
Sun, 5 Feb 2012 10:26:45 +0100 |
User-agent: |
Mutt/1.4.2.2i |
Hello,
There is a first functionality to modify Texinfo code, that may be used to
fill gaps in sectioning with empty @unnumbered*. This could be of use for
the Texinfo produced by pod2texi, for example. Another planned Texinfo
rewriting is the automatic addition of nodes and menu entries based on the
sectioning @-command, including the Master menu. (Those functionality could
be enhanced by having a possibility to keep @values, @include and user
define macros unexpanded, but that's to be done after the release).
I would envision only one command to do all the Texinfo rewriting, which
should simply call a parser on some Texinfo, perform the tree rearrangements
and write the resulting Texinfo. A list of modifications to be done could
be passed as a mandatory option, or be the first argument, like
command fill_sectioning_gaps,complete_master_menu file.texi --ouput=rewritten/
Now, it could also be texi2any that does that. That would imply setting
a new output format, Texinfo, not like with -E as a by-product, but
as a main output. Default output file would be stdout, and @include files
would be rewritten only if a subdir is specified. This possibility
complexifies texi2any a bit. But it also offers a possibility to make
transformations to the texinfo tree on the fly, just after the texinfo tree
parsing. Another (short-term) advantage is that there is less need in that
setting to keep @include/@value/user @-macros. The transformations list
would certainly require a new command line, maybe --transform (although
in a first step, a customization variable may be enough).
Opinions?
(As a side note, I think that I'll add the possibility to output Texinfo
to texi2any as the main output in any case, with a customization variable).
--
Pat
- new command to manipulate texinfo files?,
Patrice Dumas <=