From: "GEORGE WHITE, BIOLOGICAL OCEANOGRAPHY DIVISION"
Newsgroups: comp.text.tex
Subject: Re: TeX's file handling
Date: Thu, 9 Apr 1992 11:07 AST
Organization: Info-Tex<==>Comp.Text.Tex Gateway
X-Gateway-Source-Info: Mailing List

>
> As a style designer using LaTeX, I have desired to do the very thing that Dan
> pointed out:
>
> > ....a style file designer might conceivably want
> > to create temporary files....or perhaps back-up a previously
> > created file (by renaming) before writing a new version
>
> In fact, I may even wish to invoke shell scripts of a general nature.
> Apart from the fact that TeX is now frozen, these capabilities
> certainly are worth discussing. Knuth had suggested that \write16 might
> send its output to a stream that the OS would interpret and execute.
> There is even an existing TeX (VP/CMS) that has this capability
> (tracing, I believe, back to Chris Thompson (?)). Of course,
> exercising this capability makes the macro package or, resp. document
> instance system-dependent. There is even the possibility of a
> TeX-driving virus or trojan horse if this were done.
>
tex the program should be viewed as a component that can be used as
a building block to create a document processing application.  Every
feature that is added increases the potential for introducing bugs
(or incorporating a buggy routine from a vendor library) as well as
creating side effects that may have unexpected consequences when tex
is used in a new environment.  There have been a number of articles
describing the use of the Unix document processing tools, e.g., Aho and
Sethi, "Maintaining Cross References in Manuscripts", Softw.--
Practice and Experience 18(1):1-13 (1988).  The same approach works
with tex.  For those who object that this approach only
works under Unix I will point out that 1) the growth of Unix-based
OS is partly supported by the benefits of being able to construct
applications by hooking together components, and 2) emerging open
systems standards are fostering the spread of this approach to
other environments.

> An interesting parallel is the Mathematica application, which has a
> shell escape on Unix systems, and a general message-passing interface
> (MathLink) implemented under Unix via named pipes (I believe), and
> under Win, NeXT, and Mac via IAC.
>
Mathematica is not comparable to tex, but it would be very nice to
see more examples of tex-driven document processing systems with
the sort of interface that Mathematica provides.  There are a few.

> I certainly encourage implementors to consider the ramifications of a
> capability for TeX to communicate outside itself, the most robust and
> functional way to implement such a capability, and some means of
> making the system as implementation independent as possible. The future
> of computing certainly includes much interapplication communication, and
> the future TeX will certainly benfit from participating.
>
tex is already participating.  The basic task of tex is to create a
dvi file.  Many packages that use the TeX language to implement
additional features could be implemented outside of tex using
tools designed for manipulating documents.  The current practical
reality is that such tools are not well known are readily available
except under Unix, but our effort would be better spent promoting
better design of the environments in which we use tex than in
changing tex to compensate for a poor environment.

 +-------------------------------------------------------------------------+
 | George N. White III               | Internet: GWhite@BIOnet.BIO.DFO.ca  |
 | Biological Oceanography Division  |   DFOnet: BIOnet::GWhite            |
 | Bedford Institute of Oceanography | Telemail: (see Sprintmail)          |
 | P.O. Box 1006                     | phone:    902.426.8509 (lab)        |
 | Dartmouth, Nova Scotia            | (09:00-17:00) 426.3793 (emergencies)|
 | CANADA               B2Y 4A2      |  TZ=AST4ADT   426.9388 (FAX)        |
 | Sprintmail:(C:usa,A:telemail,P:internet,ID:<gwhite(a)bionet.bio.dfo.ca>)|
 +-------------------------------------------------------------------------+