[texhax] multiple pdfs from one dtx
Arno.Trautmann at gmx.de
Sun Dec 26 22:17:23 CET 2010
Heiko Oberdiek wrote:
> On Sun, Dec 26, 2010 at 11:36:21AM +0100, Arno Trautmann wrote:
>> Heiko Oberdiek wrote:
>>> On Sat, Dec 25, 2010 at 11:03:11PM +0100, Arno Trautmann wrote:
>>>> I want to produce two different sty files and corresponding
>>>> documentations (pdfs). As the sty files belong together (say, an
>>>> internal and external version), I want to keep maintainance as easy as
>>>> possible and therefore use one dtx file for everything. Now, is there a
>>>> possibility to produce two pdfs from one dtx file?
>>> You can put two documentation driver files in the dtx file and
>>> process both, e.g.:
>>> 1. tex mypackage.ins
>>> unpacks mypackage-foo.drv and mypackage-bar.drv,
>>> and other files like mypackage-foo.sty, mypackage-bar.sty.
>>> 2. pdflatex mypackage-foo.drv
>>> generates mypackage-foo.pdf
>>> 3. pdflatex mypackage-bar.drv
>>> generates mypackage-bar.pdf
>> I think I understand this conceptually, but to make it a bit more
>> confusing, I am using a "self-contained" dtx, stolen from the fontspec
>> package. So I have all necessary files in only one dtx, but it makes
>> things quite complex, I guess. So I have no idea how to translate your
>> solution to a package written in the following way.
>> Could you give me a hint where to put the documentation for the external
>> package? I guess I have to use a second driver tag, but am not shure how.
> There are many interpretations of DTX. What's yours?
A file that contains the source code and documentation of something that
has to do with TeX. And which produces executable files and
documentation pdfs after fed to (lua/pdf)(la)tex.
>> % \iffalse
>> \input docstrip.tex
>> % \fi
> Thus you want that "(pdf)latex mypackage.dtx" unpacks the files
> and generates the documentation?
> However you want to have *two* output PDF files. That requires
> two (pdf)latex runs.
Is it possible to start a second TeX-run from the first one without
having to specify --shell-escape?
> What can be done with the DTX file depends on
> * your interpretation of the DTX format,
> what should happen is "tex" or "(pdf)latex" is called
> on the .dtx file?
I want to produce the .sty-file(s) and the .pdf-file(s).
> * the higher package layout, how many documentation
> files, ...
It's a very simple package with just some definitions and some
> * how do you want that the user/maintainer unpacks
> the files.
Maintainer am I, user will get the "external" .sty and the .pdf file.
Distribution via CTAN will not happen as it is a private package.
> * how the user/maintainer generates the documentation.
Only maintainer should generate anything.
> The two latest questions are less important, if you
> provide a .tds.zip
As mentioned, no wide distribution is planned. Else, there would be no
need for an "external" and "internal" version.
> I don't know, why you want to have two PDF files, one
One file for the publisher, one for the author. Sorry that I did not
make this clear. Therefore, no need for texdoc to find anything!
Thanks for all your comments and suggestions,
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 262 bytes
Desc: OpenPGP digital signature
More information about the texhax