Changes

Jump to navigation Jump to search
11,611 bytes added ,  20:11, 20 August 2012
Todo --> todo
< {{todo|On this page I'd like to see some texexec trickery and explanations. --[[texexec.iniUser:Patrick Gundlach|pg]] >}}
{{todonote|On this This page I'd like to see some texexec trickery and explanations. documents the Perl version of TeXExec, which has (relatively recently) been replaced by a ruby re--[[User:Patrick Gundlach|pg]]implementation}}
==Command-Line Options==
<table><tr><td>{| | --alone<td> | bypass utilities (e.g. fmtutil for non-standard fmt)<tr><td>|- | --arrange<td> | process and arrange<tr><td>|- | --automprun<td> | MetaPost at runtime when needed<tr |- valign="top"><td>| --autopdf<td> | Open the pdf viewer after the texexec run. [[#autopdf|See below]]. <tr><td>|- | --batch<td> | run in batch mode (don't pause)<tr><td>|- | --centerpage<td> | center the page on the paper<tr><td>|- | --color<td> | enable color (when not yet enabled)<tr><td>|- | --environment = name<td> | load some environments first. Name is: list of environments<tr><td>|- | --fast<td> | skip as much as possible<tr |- valign="top"><td>| --figures = (a|&#124;b|&#124;c)<td> | typeset figure directory
; a : room for corrections
; b : just graphics
; c : one (cropped) per page
<tr><td>|- | --final<td> | add a final run without skipping<tr><td>|- | --format = name<td> | fmt file. name: format file (memory dump)<tr><td>|- | --help<td> | show this or more, e.g. '--help interface'<tr><td>|- | --input = name<td> | input file (if used). name: filename<tr><td>|- | --interface = (cz|&#124;de|&#124;en|&#124;it|&#124;nl|&#124;uk)<td> | user interface <tr><td>|- | --language = lang<td> | main hyphenation language. lang: standard abbreviation<tr><td>|- | --listing<td> | produce a verbatim listing<tr><td>|- | --make<td> | build format files<tr><td>|- | --mode = list<td> | running mode. list: modes to set<tr><td>|- | --module<td> | typeset tex/pl/mp module<tr><td>|- | --mpgraphic| process mp file to stand-alone graphics|- | --mpformat = name<td> | mem file. name: format file (memory dump)<tr><td>|- | --mptex<td> | run an MetaPost plus btex-etex cycle<tr><td>|- | --mpxtex<td> | generatet an MetaPostmpx file<tr><td>|- | --noarrange<td> | process but ignore arrange<tr><td>|- | --nomp<td> | don't run MetaPost at all<tr><td>|- | --nomprun<td> | don't run MetaPost at runtime<tr><td>|- | --nonstop<td> | run in non stop mode (don't pause)<tr><td>|- | --once<td> | run TeX only once (no TeXUtil either)<tr |- valign="top"><td>| --output<td> | specials to use. Can be one of{|| ; dvipdfm || : Mark Wicks' dvi to pdf converter |-| ; dvipdfmx || : Jin-Hwan Cho's extended dvipdfm |-| ; dvips || : Thomas Rokicky's dvi to ps converter|-| ; dvipsone || : YandY's dvi to ps converter |-| ; dviwindo || : YandY's windows previewer |-| ; pdftex || : Han The Than's pdf backend|- | --pages=(even&#124;odd&#124;x,y:z)| pages to output. x,y:z: pages x and y to z|- | --paperformat=(AB&#124;A:B&#124;A*B)| paper input and output format. a4a3: A4 printed on A3, a5a4: A5 printed on A4|- | --paperoffset=dim| extra offset|- | --passon| switches to pass to TeX (--src for MikTeX)|- | --path=string| document source path. string: path|- | --pdf| produce PDF directly using pdf(e)tex|- | --pdfarrange| arrange pdf pages|- | --pdfcombine| combine pages to one page|- | --pdfcopy| scale pages down/up|- | --pdfselect| select pdf pages|- | --pdfsplit| split pdf file into pages|- | --print=(up&#124;down) | page imposition scheme. down=2 rotated pages per sheet doubleside, up=2 pages per sheet doublesided|- | --result=filename| resulting file will have that filename|- | --runs=n| maximum number of TeX runs. n: number of runs|- | --screensaver| turn graphic file into a (pdf) full screen file|- | --setfile| load environment (batch) file|- | --silent| minimize (status) messages|- | --suffix=string| resulting file suffix. string: suffix|- | --tex=name| TeX binary. name: binary of executable|- | --texroot=path| root of tex trees. path: tex root|- | --textree=path| additional texmf tree to be used. path: subpath of tex root|- | --texutil| force TeXUtil run|- | --usemodule=name| load some modules first name: list of modules|- | --verbose| shows some additional info|- | --version| display various version information|- | --xmlfilter=name| apply XML filter. name: list of filters
|}
<tr><td>--pages = (even|odd|x,y:z)<td> pages to output. x,y:z: pages x and y to z
<tr><td>--paper = AB<td> paper input and output format. a4a3: A4 printed on A3, a5a4: A5 printed on A4
<tr><td>--passon<td> switches to pass to TeX (--src for MikTeX)
<tr><td>--path = string<td> document source path. string: path
<tr><td>--pdf<td> produce PDF directly using pdf(e)tex
<tr><td>--pdfarrange<td> arrange pdf pages
<tr><td>--pdfcombine<td> combine pages to one page
<tr><td>--pdfcopy<td> scale pages down/up
<tr><td>--pdfselect<td> select pdf pages
<tr><td>--print = (up|down) <td> page imposition scheme. down = 2 rotated pages per sheet doubleside, up = 2 pages per sheet doublesided
<tr><td>--result = filename<td> resulting file will have that filename
<tr><td>--runs = n<td> maximum number of TeX runs. n: number of runs
<tr><td>--screensaver<td> turn graphic file into a (pdf) full screen file
<tr><td>--setfile<td> load environment (batch) file
<tr><td>--silent<td> minimize (status) messages
<tr><td>--suffix= string<td> resulting file suffix. string: suffix
<tr><td>--tex = name<td> TeX binary. name: binary of executable
<tr><td>--texroot = path<td> root of tex trees. path: tex root
<tr><td>--textree = path<td> additional texmf tree to be used. path: subpath of tex root
<tr><td>--texutil<td> force TeXUtil run
<tr><td>--usemodule = name<td> load some modules first name: list of modules
<tr><td>--verbose<td> shows some additional info
<tr><td>--version<td> display various version information
<tr><td>--xmlfilter = name<td> apply XML filter. name: list of filters
</table>
== Some features explained in detail ==
=== autopdf ===
Currently works only on Windows and Linux. On Mac OS X there is no way to do this for Acrobat Reader 7.0 and Preview.app in a sophisticated way (= keep view), since they are not (apple-)scriptable. You can use TeXniscope, TeXshop or iTeXMac that does that automatically.
 
=== nonstopmode ===
 
Useful when running texexec from an editor and do not want it to stop for errors.
 
=== mpgraphic ===
 
texexec --mpgraphic file.mp
 
creates a temporary tex file, with
 
<texcode>
\setoutput[pdftex]
\setupcolors[state=start]
% Some lines for font maps
\starttext
\startTEXpage
\convertMPtoPDF{file.1}{1}{1}
\stopTEXpage
\startTEXpage
\convertMPtoPDF{file.2}{1}{1}
\stopTEXpage
 
% etc....
 
\stoptext
</texcode>
 
So, in the end you get a single pdf with each figure on different page.
 
= Examples =
 
== Produce dvi output ==
By default <code>--dvi</code> also produces a ps file. If you just want a dvi file
 
texexec --dvi test --nobackend
 
== Select n pages from a pdf file ==
 
texexec --pdfselect --select=1:5 blabla.pdf
 
== Split pdf file ==
 
texexec --pdfsplit somefile.pdf
 
== Combine two or more PDF files into one file ==
 
texexec --pdfcombine --nobanner --result=result.pdf 1.pdf 2.pdf
 
== Concatenate two or more PDF files into one file ==
 
texexec --pdfcopy --result=result.pdf 1.pdf 2.pdf
 
== Check the status of various scripts ==
 
texexec --check
 
This should give an output like
 
TeXExec | current distribution: web2c
TeXExec | context source date: 2006.10.27 15:16
TeXExec | format path: E:/isoimage/usr/local/context/tex/texmf-mswin/web2c/unsetengine E:/isoimage/usr/local/context/tex/texmf-mswin/web2c
TeXExec | start of analysis
TeXExec | processing document 'texexec'
TeXExec | tex processing method: context
TeXExec | writing option file texexec.top
TeXExec | using randomseed 1306
TeXExec | tex engine: pdftex
TeXExec | tex format: cont-en
TeXExec | progname: context
 
This is pdfTeX, Version 3.141592-1.40.0-beta-20060213 (Web2c 7.5.5)
\write18 enabled.
(e:\isoimage\usr\local\context\tex\texmf-local/web2c/natural.tcx)
entering extended mode
(./texexec.tex
 
ConTeXt ver: 2006.10.27 15:16 MK II fmt: 2006.10.29 int: english/english
language : language en is active
system : cont-new loaded
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-new.tex
systems : beware: some patches loaded from cont-new.tex
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-new.mkii))
system : cont-old loaded
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-old.tex
loading : Context Old Macros
)
system : cont-fil loaded
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-fil.tex
loading : Context File Synonyms
)
system : cont-sys loaded
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/user/cont-sys.tex)
bodyfont : 12pt rm is loaded
language : patterns nl->texnansi:texnansi->1->2:3 nl->ec:ec->2->2:3 fr->
texnansi:texnansi->3->2:3 fr->ec:ec->4->2:3 de->texnansi:texnansi->5->2:3 de->e
c:ec->6->2:3 it->texnansi:texnansi->7->2:3 it->ec:ec->8->2:3 pt->texnansi:texna
nsi->9->2:3 pt->ec:ec->10->2:3 hr->ec:ec->11->2:3 pl->pl0:pl0->12->2:3 pl->ec:e
c->13->2:3 pl->qx:qx->14->2:3 cz->il2:il2->15->2:3 cz->ec:ec->16->2:3 sk->il2:i
l2->17->2:3 sk->ec:ec->18->2:3 sl->ec:ec->19->2:3 ru->t2a:t2a->21->2:3 en->ec:e
c->22->2:3 uk->ec:ec->23->2:3 us->ec:ec->24->2:3 agr->agr:agr->25->2:3 da->ec:e
c->26->2:3 sv->ec:ec->27->2:3 af->ec:ec->28->2:3 no->ec:ec->29->2:3 deo->ec:ec-
>30->2:3 es->ec:ec->31->2:3 ca->ec:ec->32->2:3 la->ec:ec->33->2:3 ro->ec:ec->34
->2:3 tr->ec:ec->35->2:3 fi->ec:ec->37->2:3 hu->ec:ec->38->2:3 loaded
specials : tex,postscript,rokicki loaded
system : texexec.top loaded
(./texexec.top
specials : loading definition file tpd
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/spec-tpd.tex
specials : loading definition file fdf
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/spec-fdf.tex
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/spec-fdf.mkii))
specials : fdf loaded
)
specials : fdf,tpd loaded
)
systems : system commands are enabled
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/sort-def.tex)
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/sort-lan.tex)
systems : begin file texexec at line 1
fonts : resetting map file list
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-empty.map}
fonts : using map file: texnansi-public-lm
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/texnans
i-public-lm.map}
fonts : using map file: original-base
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-base.map}
fonts : using map file: ec-public-lm
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/ec-publ
ic-lm.map}
fonts : using map file: ec-base
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/ec-base
.map}
fonts : using map file: original-ams-base
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-ams-base.map}
fonts : using map file: original-ams-euler
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-ams-euler.map}
fonts : using map file: original-public-lm
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-public-lm.map}
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/pdfr-ec.tex)
[1.1]
systems : end file texexec at line 3
){e:\isoimage\usr\local\context\tex\texmf/fonts/enc/dvips/lm/lm-ec.enc}<e:\iso
image\usr\local\context\tex\texmf/fonts/type1/public/lm/lmr12.pfb>
Output written on texexec.pdf (1 page, 23276 bytes).
Transcript written on texexec.log.
TeXExec | runtime: 0.47
 
TeXExec | processing document 'texexec'
TeXExec | tex processing method: context
TeXExec | writing option file texexec.top
TeXExec | using randomseed 498
TeXExec | tex engine: pdftex
TeXExec | tex format: cont-nl
TeXExec | progname: context
This is pdfTeX, Version 3.141592-1.40.0-beta-20060213 (Web2c 7.5.5)
\write18 enabled.
(e:\isoimage\usr\local\context\tex\texmf-local/web2c/natural.tcx)
entering extended mode
(./texexec.tex
 
ConTeXt ver: 2006.10.27 15:16 MK II fmt: 2006.10.29 int: dutch/dutch
taal : taal nl is actief
systeem : cont-new geladen
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-new.tex
systems : beware: some patches loaded from cont-new.tex
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-new.mkii))
systeem : cont-old geladen
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-old.tex
loading : Context Old Macros
)
systeem : cont-fil geladen
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/cont-fil.tex
loading : Context File Synonyms
)
systeem : cont-sys geladen
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/user/cont-sys.tex)
korps : 12pt rm wordt geladen
taal : patronen nl->texnansi:texnansi->1->2:2 nl->ec:ec->2->2:2 fr->
texnansi:texnansi->3->2:2 fr->ec:ec->4->2:2 de->texnansi:texnansi->5->2:2 de->e
c:ec->6->2:2 it->texnansi:texnansi->7->2:2 it->ec:ec->8->2:2 pt->texnansi:texna
nsi->9->2:2 pt->ec:ec->10->2:2 hr->ec:ec->11->2:2 pl->pl0:pl0->12->2:2 pl->ec:e
c->13->2:2 pl->qx:qx->14->2:2 cz->il2:il2->15->2:2 cz->ec:ec->16->2:2 sk->il2:i
l2->17->2:2 sk->ec:ec->18->2:2 sl->ec:ec->19->2:2 ru->t2a:t2a->21->2:2 en->ec:e
c->22->2:2 uk->ec:ec->23->2:2 us->ec:ec->24->2:2 agr->agr:agr->25->2:2 da->ec:e
c->26->2:2 sv->ec:ec->27->2:2 af->ec:ec->28->2:2 no->ec:ec->29->2:2 deo->ec:ec-
>30->2:2 es->ec:ec->31->2:2 ca->ec:ec->32->2:2 la->ec:ec->33->2:2 ro->ec:ec->34
->2:2 tr->ec:ec->35->2:2 fi->ec:ec->37->2:2 hu->ec:ec->38->2:2 geladen
specials : tex,postscript,rokicki geladen
systeem : texexec.top geladen
(./texexec.top
specials : definitiefile tpd wordt geladen
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/spec-tpd.tex
specials : definitiefile fdf wordt geladen
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/spec-fdf.tex
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/spec-fdf.mkii))
specials : fdf geladen
)
specials : fdf,tpd geladen
)
systems : system commands are enabled
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/sort-def.tex)
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/sort-lan.tex)
systems : begin file texexec at line 1
fonts : resetting map file list
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-empty.map}
fonts : using map file: texnansi-public-lm
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/texnans
i-public-lm.map}
fonts : using map file: original-base
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-base.map}
fonts : using map file: ec-public-lm
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/ec-publ
ic-lm.map}
fonts : using map file: ec-base
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/ec-base
.map}
fonts : using map file: original-ams-base
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-ams-base.map}
fonts : using map file: original-ams-euler
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-ams-euler.map}
fonts : using map file: original-public-lm
{e:\isoimage\usr\local\context\tex\texmf-local/fonts/map/pdftex/context/origina
l-public-lm.map}
(e:\isoimage\usr\local\context\tex\texmf-local/tex/context/base/pdfr-ec.tex)
[1.1]
systems : end file texexec at line 3
){e:\isoimage\usr\local\context\tex\texmf/fonts/enc/dvips/lm/lm-ec.enc}<e:\iso
image\usr\local\context\tex\texmf/fonts/type1/public/lm/lmr12.pfb>
Output written on texexec.pdf (1 page, 23276 bytes).
Transcript written on texexec.log.
TeXExec | runtime: 0.441
TeXExec | end of analysis
 
TeXExec |
TeXExec | TeXExec | version 6.2.0 - 1997-2006 - PRAGMA ADE/POD
TeXExec | TeXUtil | version 9.1.0 - 1997-2005 - PRAGMA ADE/POD
TeXExec | CtxTools | version 1.3.3 - 2004/2006 - PRAGMA ADE/POD
TeXExec |
TeXExec | testing interface en
TeXExec | pdfTeX Version 3.141592-1.40.0-beta-20060213 (Web2c 7.5.5)
TeXExec | ConTeXt ver: 2006.10.27 15:16 MK II fmt: 2006.10.29 int: english/english
TeXExec |
TeXExec | testing interface nl
TeXExec | pdfTeX Version 3.141592-1.40.0-beta-20060213 (Web2c 7.5.5)
TeXExec | ConTeXt ver: 2006.10.27 15:16 MK II fmt: 2006.10.29 int: dutch/dutch
 
= TeXTools =
 
<i>(should be moved on a separate page, but it's stil almost empty anyway)</i>
 
To update your TeX tree to the most recent version of kurier fonts for example, you can use
textools --updatetree kurier-tex e:\tex\texmf
with <code>kurier-tex</code> being the new content for your old TEXMF tree (if it were) located under <code>e:\tex\texmf</code> (change folder names accordingly).
This will tell you what will be updated, merged and deleted (use <code>--force</code> to really do it)

Navigation menu