<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html;
      charset=windows-1252">
  </head>
  <body>
    <div class="moz-cite-prefix">On 24/07/2021 9:00 am, Paul A. Rubin
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:7994c9f1-1931-c3ee-21a1-9cb042422a10@gmail.com">
      <meta http-equiv="Content-Type" content="text/html;
        charset=windows-1252">
      <div class="moz-cite-prefix">On 7/23/21 4:14 PM, Rudi Gaelzer
        wrote:<br>
      </div>
      <blockquote type="cite" cite="mid:7235727.J7v0fY0zR8@landau">
        <meta http-equiv="content-type" content="text/html;
          charset=windows-1252">
        <br>
        <p
          style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Is
          there a way to instruct Lyx to write certain auxiliary files
          into the local directory, instead of in /tmp/lyx_tmpdirxxx?</p>
        <br>
        <fieldset class="mimeAttachmentHeader"></fieldset>
      </blockquote>
      Is it LyX or LaTeX (pdflatex?) that writes the auxiliary files? I
      suspect the latter, in which case I'm pretty sure the answer to
      your question is no. You could create a custom export format and
      tell LyX to invoke a shell script (written by you) that would run
      whatever LaTeX commands were needed and then copy the selected
      files to the local directory (which I believe you can convince LyX
      to pass as an argument to the script). That's complicated enough
      that you might be better off just writing a script that copies the
      target files to the local directory and run it manually after
      compiling documents.<br>
      <br>
    </blockquote>
    <p>I haven't followed this thread with any attention so may well
      have missed the point, but I wonder if LyX's copier mechanism is
      what you want? I'm thinking of the script ext_copy.py that comes
      with LyX (in Resources/scripts). For example, to copy the *.aux
      files back to your document directory from the temp directory,  in
      Tools>Preferences>File Handling>File Formats select the
      format PDF (pdflatex) and in the Copier slot put<br>
    </p>
    <p>python -tt $$s/scripts/ext_copy.py -e pdf,aux -d $$i $$o</p>
    <p>then click OK. Now when you export to pdf by the pdflatex route,
      not only will you get the pdf in your document directory but also
      any aux files. <br>
    </p>
    <p>If you want to look at the aux files without the burden of
      compiling to pdf, a good trick is to export to Plain text, which
      is quick even for large complex documents, and in the Copier slot
      under Plain text to enter</p>
    <p>python -tt $$s/scripts/ext_copy.py -e aux -d $$i $$o</p>
    <p>Notice that only files with the extension aux are to be copied
      back. That means the plain text file resulting from the export,
      which you are unlikely to be interested in, stays in the temp
      directory and doesn't clutter your document directory, but the aux
      files do get copied back to there.</p>
    <p>Andrew<br>
    </p>
  </body>
</html>