[NTG-context] Write to tuc file

denis.maier at ub.unibe.ch denis.maier at ub.unibe.ch
Sat Feb 27 22:25:02 CET 2021


Thanks, that's helpful. So to automate this, I'll just need to get the pagenumbers from the log file. I'll give it a try.
________________________________________
Von: Hans Hagen <j.hagen at xs4all.nl>
Gesendet: Samstag, 27. Februar 2021 19:26:52
An: Maier, Denis Christian (UB); mailing list for ConTeXt users
Betreff: Re: AW: [NTG-context] Write to tuc file

On 2/27/2021 6:28 PM, denis.maier at ub.unibe.ch wrote:
> It's a book that will be published in two volumes, continually paginated.
> In the end I need two pdf files, but I thought it might be easier to treat them as one volume and just split the files with some external tool afterwards.
>
> I could also treat them as two individual books, but then I'd have to get the last page number of volume 1 in volume 2.
On the console you see the pagenumbers right? What you need is the
realpage. You could actually do something:

\dorecurse{10}{\samplefile{tufte}\page}
\appendetoks
     \writestatus{!!!!!}{}
     \writestatus{!!!!!}{SPLIT HERE: \the\realpageno}
     \writestatus{!!!!!}{}
\to \everystoptext
\dorecurse{10}{\samplefile{tufte}\page}

and then use this number in:

context --extra=select --selection=1:4    oeps.pdf --once --autopdf
context --extra=select --selection=5:9999 oeps.pdf --once --autopdf

(We can actually relate tags to pages so maybe I will make something to
  pick that up from the tuc file.)

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------


More information about the ntg-context mailing list