[texhax] Can I Parsing with TeX ?
William Adams
will.adams at frycomm.com
Wed Aug 15 15:47:16 CEST 2007
On Aug 14, 2007, at 7:52 PM, wa2n wrote:
> Can TeX doing parsing or regexp ?
>
> or the question is
> how can I replace something in tex source (.tex) while I'm
> compiling the
> source (make it .dvi) ?
Tony's answer was excellent, but there has been a recent new
development and there are some alternatives which he didn't mention:
- luatex, the successor to pdftex builds in the lua scripting
language, so makes this sort of thing a feature, http://
www.luatex.org/ --- they've begun making betas available, so you
could try it now.
- alternately, one could, using multiple passes, write out a file,
use shell escape to process it, then read back in the processed
version, or
- use a makefile to manage your TeX compilation and set the
processing to happen using that (call tex to force the extraction,
then call your scripts on the extracted bits, then call tex which is
then able to read in the processed bits)
William
--
William Adams
senior graphic designer
Fry Communications
More information about the texhax
mailing list