[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

A little mumbo-jumbo and we have soup

From: Bruce Korb
Subject: A little mumbo-jumbo and we have soup
Date: Sat, 12 May 2001 20:15:02 -0700

Each of the eight command strings is stored as a defined string,
but they are simultaneously templates, too.  They get sucked
into the output documents in a way that only the father of
AutoGen could ever love:-)


[= (out-push-new ".lt.tmp")    =][=
   string[LINK_STRING].text    =][=
   (out-pop)                   =][=
   INCLUDE ".lt.tmp"           =]

and, also for ltstr.c:

tSCC z[= (string-capitalize! (get "str_name")) =]Cmd[] =
[= (out-push-new ".lt.tpl") =][=
   text                     =][=
   (out-push-new "") =][=
   INCLUDE ".lt.tpl"        =][=
   (kr-string (shell "cat ; rm -f .lt.*")) =];

Now, common functions can be dropped into a template
library and used for generating both the bare script
and the script within a program.

It would elminate an extra push/emit/pop to put the
text into separate template files, but I want to
think about it a bit.  I will probably do that later.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]