public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: Bastien DUMONT <bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org>
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: pandoc to pdf: how to synchronize files output by package ?
Date: Thu, 16 Feb 2023 12:22:42 +0000	[thread overview]
Message-ID: <Y+4gEulW/6ZURhy3@localhost> (raw)
In-Reply-To: <a0909aa4-e617-4e65-b760-ac617fd192c2n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>

A possible solution would be to use Pandoc to produce the TeX file, then process the TeX file yourself with LaTeX.

Le Thursday 16 February 2023 à 02:00:05AM, Pierre-Antoine BRAMERET a écrit :
> Hi,
> 
> I use a package that reads and writes files to synchronize counters.
> The package is custom but it is based on this question: https://
> tex.stackexchange.com/questions/124103/how-to-create-a-fixed-counter.
> 
> The result is that I need to input files:
> \InputIfFileExists{\jobname.notes}{}{}
> 
> And output files:
> \immediate\openout\jjdbout=\jobname.notes
> \immediate\write\jjdbout{\unexpanded\expandafter{\jjdbnotes}}
> 
> The problem is that I cannot keep track of this file, as pandoc runs pdflatex
> in a temporary directory.
> 
> The hacks I tried:
> - write somewhere else but pdflatex correctly prevents that,
> - using \write18 to execute some commands, but in that case I don't know the 
> temporary path to synchronize my files to ; I thought it was in TEXMFOUTPUT,
> but this env variable only points to the first run started by pandoc (so it's
> okay to put the files there beforehand, but not to fetch the updated versions),
> - using \write18 and the package currfile, but if I understood correctly,
> currfile relies on files already existing so I cannot know to which path I have
> to put my files before hand.
> 
> Is there something I missed to copy files to output before pandoc calls the pdf
> engine and fetch files after it finished?
> How could we do that?
> 
> Thanks,
> Best,
> 
> 
> --
> You received this message because you are subscribed to the Google Groups
> "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to [1]pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit [2]https://groups.google.com/d/msgid/
> pandoc-discuss/a0909aa4-e617-4e65-b760-ac617fd192c2n%40googlegroups.com.
> 
> References:
> 
> [1] mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> [2] https://groups.google.com/d/msgid/pandoc-discuss/a0909aa4-e617-4e65-b760-ac617fd192c2n%40googlegroups.com?utm_medium=email&utm_source=footer

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/Y%2B4gEulW/6ZURhy3%40localhost.


  parent reply	other threads:[~2023-02-16 12:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-16 10:00 Pierre-Antoine BRAMERET
     [not found] ` <a0909aa4-e617-4e65-b760-ac617fd192c2n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-02-16 12:22   ` Bastien DUMONT [this message]
2023-02-16 14:31     ` Pierre-Antoine BRAMERET

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Y+4gEulW/6ZURhy3@localhost \
    --to=bastien.dumont-vwifzpto/vqstnjn9+bgxg@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).