emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <mail@nicolasgoaziou.fr>
To: Stig Brautaset <stig@brautaset.org>
Cc: emacs-orgmode@gnu.org, Rasmus <rasmus@gmx.us>
Subject: Re: Export to pdf when path name has ~
Date: Thu, 26 May 2016 21:52:48 +0200	[thread overview]
Message-ID: <8760u0d2b3.fsf@saiph.selenimh> (raw)
In-Reply-To: <m0h9dncryo.fsf@brautaset.org> (Stig Brautaset's message of "Tue, 24 May 2016 17:59:27 +0100")

Hello,

Stig Brautaset <stig@brautaset.org> writes:

> And, indeed, running pdflatex on that file works perfectly fine from the shell:
>
> #+BEGIN_EXAMPLE
> 17:37:57 /tmp> /Library/TeX/texbin/pdflatex ~/Org/TODO.tex
> This is pdfTeX, Version 3.14159265-2.6-1.40.16 (TeX Live 2015) (preloaded format=pdflatex)
>  restricted \write18 enabled.
> entering extended mode
> (/Users/stig/Org/TODO.tex
> LaTeX2e <2015/01/01>
>
> [...]
>
> Output written on TODO.pdf (10 pages, 206446 bytes).
> Transcript written on TODO.log.
> #+END_EXAMPLE
>
>
> ... except if you use the full path (rather than the symlink), in which case
> pdflatex chockes on the filename:
>
> #+begin_example
> 17:27:25 /tmp> pdflatex "/Users/stig/Library/Mobile Documents/com~apple~CloudDocs/Org/TODO.tex"
> This is pdfTeX, Version 3.14159265-2.6-1.40.16 (TeX Live 2015) (preloaded format=pdflatex)
>  restricted \write18 enabled.
> entering extended mode
> ! I can't find file `"/Users/stig/Library/Mobile Documents/com"'.
> <to be read again> 
>                    \protect 
> <*> "/Users/stig/Library/Mobile Documents/com~
>                                               apple~CloudDocs/Org/TODO.tex"

Indeed. It seems pdflatex doesn't like the ~ sign excepted at the
beginning of the filename. It doesn't seem to be Org related though.

In any case, I'm wondering if we really need to send the full canonical
path (as returned by `file-truename') of the tex file to the pdflatex
process.

For example, we could set `default-directory' to the directory of the
tex file and provide only relative filename with %f. If needed, %F may
be used for the full path. I don't think it would introduce
incompatibilities.

WDYT?

Regards,

-- 
Nicolas Goaziou

  reply	other threads:[~2016-05-26 19:53 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-24 16:59 Export to pdf when path name has ~ Stig Brautaset
2016-05-26 19:52 ` Nicolas Goaziou [this message]
2016-05-26 22:30   ` Stig Brautaset
2016-05-27  7:04   ` Rasmus
2016-05-29 22:15     ` Nicolas Goaziou
2016-06-10 14:58       ` Stig Brautaset
2016-06-10 21:52         ` Nicolas Goaziou
2016-06-11  0:10           ` Stig Brautaset
2016-08-31 12:51             ` Stig Brautaset

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

  List information: https://www.orgmode.org/

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

  git send-email \
    --in-reply-to=8760u0d2b3.fsf@saiph.selenimh \
    --to=mail@nicolasgoaziou.fr \
    --cc=emacs-orgmode@gnu.org \
    --cc=rasmus@gmx.us \
    --cc=stig@brautaset.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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).