mailing-list for TeXmacs Users

Text archives Help


Re: [TeXmacs] Re: subtracting lines from a include


Chronological Thread 
  • From: Corey Sweeney <address@hidden>
  • To: Bas Spitters <address@hidden>
  • Cc: address@hidden
  • Subject: Re: [TeXmacs] Re: subtracting lines from a include
  • Date: Tue, 9 Aug 2005 15:25:11 -0500
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ZOyD6UNVOPZr73/mRXiZSSE24DZT+J4TUAEM6pi8eibWbRUzeLZ0h8j4SWhuB0utbmZr+qv/3PD2qhcmP2YYLPU0NcZyDAkxuVWurGvSgDRH2LrXU2ySEVD6YB4DUKMTE2EJlIZAMDVKSpxcqAlMUHRZEFxYJnlGho0tnpdKUWw=

Ok, it looks like i want something like:
--------------------
;;texmacs converter thing
(define-format html-with-header
(:name "html with a extra header")
(:must-recognize (lambda (x) (equal? (substring x 0 3) "Wik"))))

(converter html-with-header html
(:shell "~/strip-header"))
----------------------

where "~/strip-header" is the program that does the translating.

Then inside my texmacs document I should call it with:
<converter-input|html-with-header|<include|~/mangled-web-file>>

or maybe just <include|~/mangled-web-file>, if everythings automatic.


Now i'm fuzzy as to how i'm supposed to pass the data across. (:shell
prog prefix-args from innfix-args to postfix-args)

Is "from" and "to" supposed to be the filenames that texmacs reads from?

like:

(:shell "~/strip-header" "temp.file.1" "temp.file.1.html")

but i'm guessing that *-args are texmacs arguments, as if they were to
the shell program, there wouldn't be 3 of them.

Or is the shell program supposed to read/write with standard
output/standard input? That'd be really easy to write into the shell
app.

Corey






On 8/9/05, Bas Spitters <address@hidden> wrote:
> On Monday 08 August 2005 23:45, Corey Sweeney wrote:
> > another idea.... it just occured to me that sessions might be right
> > for this. Here's the idea:
> >
> > Write a program that filters out the first 3 lines, then have a
> > session which calls the program and reports the output. Something
> > like \session "filter3lines.exe {filename}". Then write a macro to
> > wrap it, so something like \include-filtered {filename}, then presents
> > it?
> >
> > I havn't worked in sessions yet. Does anyone this this would work?
>
> For instance, have a look at my recent post of a generic latex plugin at
> texmacs-dev. (and look at Joris' answer).
>
> Bas
>



Archive powered by MHonArc 2.6.19.

Top of page