Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!cbatt!ihnp4!houxm!houxu!jhv From: jhv@houxu.UUCP Newsgroups: net.sources.bugs Subject: Re: Neat little alias & technique to facilite troff Message-ID: <920@houxu.UUCP> Date: Fri, 16-Jan-87 15:00:44 EST Article-I.D.: houxu.920 Posted: Fri Jan 16 15:00:44 1987 Date-Received: Sat, 17-Jan-87 06:58:57 EST References: <595@cubsvax.UUCP> Organization: AT&T, Holmdel, NJ Lines: 16 Keywords: troff, word processing, text processing, typesetting Summary: Using shell "here-document" capability In article <595@cubsvax.UUCP>, peters@cubsvax.UUCP (Peter S. Shenkin) writes: > First I put this alias in my .login: > alias roff 'sed -e 1s/\.\.// -e 1s/@/!*/ -e 2,\$d !* | sh &' > Then I begin each troff source file with a line like: > ..eqn @ | ltroff -me My approach is to use the shell's "here-document" capability, putting the command line to format the document as the first line of the document, and executing the file when I need processed output, for example (to include tbl, eqn, and pic preprocessors and to print the output on an Imagen printer): tbl <