emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] compile latex on remote server


From: Charles C. Berry
Subject: Re: [O] compile latex on remote server
Date: Mon, 7 Sep 2015 09:11:00 -0700
User-agent: Alpine 2.20 (OSX 67 2015-01-07)

On Mon, 7 Sep 2015, Zhihao Ding wrote:

My emacs session is local and I am using tramp to open the org file on the
remote server. Then when I tried to export it to latex and compile I get
that error messages.

Cheers,
Zhihao


On 7 September 2015 at 14:39, Loris Bennett <address@hidden>
wrote:

Hi Zhihao,

Zhihao Ding <address@hidden> writes:

Thanks for your reply. In export if I do "l P" or "l O" I get the follow
messages

Transcript written on .//texput.log.
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian)
restricted \write18 enabled.
entering extended mode
! I can't find file `/ssh:address@hidden:/data/home/zhihao/sgt.tex'.

Is this file created on the remote server?  If so, can you open it in
Emacs via tramp?

Cheers,

Loris

I confirm this behavior. Looks like the shell command to produce the pdf runs on the remote, but uses the tramp filename.

Maybe something like

diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el
index ddbbd33..dce83af 100644
--- a/lisp/ox-latex.el
+++ b/lisp/ox-latex.el
@@ -3456,7 +3456,8 @@ Return PDF file name or an error if it couldn't be produced."
             (replace-regexp-in-string
              "%b" (shell-quote-argument base-name)
              (replace-regexp-in-string
-              "%f" (shell-quote-argument full-name)
+              "%f" (shell-quote-argument
+                    (org-babel-local-file-name full-name))
               (replace-regexp-in-string
                "%o" (shell-quote-argument out-dir) command t t) t t) t t)
             outbuf))


will fix it.

It runs on my setup - producing a pdf on the remote server, but I have not run `make test'.

HTH,

Chuck



reply via email to

[Prev in Thread] Current Thread [Next in Thread]