Hi Morgan
I spoke too soon.
Using your emacs guix container and adding
#+begin_src emacs-lisp
;;; -*- lexical-binding: t -*-
(custom-set-variables
'(org-babel-latex-preamble
#[257 "\300\207" ["\\documentclass[tikz]{standalone}\12"] 2
"\12\12(fn _)"])
'(org-babel-load-languages '((latex . t) (emacs-lisp . t))))
#+end_src
to ~/.emacs
and
#+begin_src shell
eval $(guix shell texinfo texlive-bin texlive-pgf inkscape
emacs-org-texlive-collection texlive-preview --search-paths)
#+end_src
to ~/.envrc
and creating the file ~/test.org
#+begin_src org-mode
#+name: test-html-export
#+begin_src latex :results file link :file-ext svg
\begin{tikzpicture}
\node{Hello};
\end{tikzpicture}
#+end_src
#+end_src
and activating envrc-moce with M-x envrc-mode, activating it M-x
envrc-allow and then exporting to html with C-c C-e h H I get the
following error in the *Org PDF LaTeX Output*
#+begin_src shell
/gnu/store/c6kh9i8hyi2ydkcykwi6fwfj0808hh82-bash-minimal-5.2.37/bin/sh: line 1:
pdflatex: command not found
/gnu/store/c6kh9i8hyi2ydkcykwi6fwfj0808hh82-bash-minimal-5.2.37/bin/sh: line 1:
pdflatex: command not found
/gnu/store/c6kh9i8hyi2ydkcykwi6fwfj0808hh82-bash-minimal-5.2.37/bin/sh: line 1:
pdflatex: command not found
#+end_src
Indicating the envrc-mode was not detected for html
export. (Also C-c C-e l L results in the same error). It seems there is
something going on with the latex source code block. Interestingely I can call
C-c on the source code block and properly evaluate without
error.
Thanks for any pointer!
Best,
Reza
> Reza <[email protected]> writes:
>
>> I was hoping that someone on the org-mode mailing list could confirm
>> that there was a big overhaul related to org export which may have cause
>> the change in behavior
>
> I mean even a small change could probably cause this behavior.
>
>> but it could very much be just changes in
>> emacs. I still consider this a bug, but I have to test it properly with
>> a clean emacs before coming to conclusions.
>
> Ok ok. I decided to try and reproduce this. Guix actually makes it
> very easy for me to try this.
>
> I'm going to do this using a graphical Emacs on Wayland. If you're
> following along on X11 then just add "-E '^DISPLAY$' --share=/tmp" to
> the "guix shell" command.
>
> Let's create a guix container that has just enough of the system exposed
> to do graphics and to run guix:
>
> #+begin_src elisp
> (async-shell-command
> (string-join
> (list
> "guix shell"
> "--nesting" ;; So we can use guix
> "--network"
> ;; Wayland flags
> "--preserve='^WAYLAND_DISPLAY$' --preserve='^XDG_RUNTIME_DIR$'
> --expose=$XDG_RUNTIME_DIR/$WAYLAND_DISPLAY"
> ;; Container with nothing!
> "--pure -C --no-cwd"
> ;; packages
> "emacs-pgtk"
> "emacs-envrc"
> "bash"
> "--"
> "emacs"
> ;; dark theme
> "--eval '(load-theme `modus-vivendi t)'")
> " "))
> #+end_src
>
> Now lets make a directory that contains a ".envrc" file with the
> following contents:
>
> #+begin_src sh
> eval $(guix shell texinfo texlive-bin emacs-org-texlive-collection
> --search-paths)
> #+end_src
>
> Now lets create an Org file and run 'envrc-mode' and then 'envrc-allow'.
>
> Now we can finally try making that pdf export!
>
> I type "C-c C-e l o" to see that error and oh wait... I see a PDF.
>
> IDK, works for me. I guess this is your setup after all? That was a
> little underwhelming.
>
> Well at least I got envrc setup now so maybe I'll have some fun playing
> with that.
>
> Looks like Org babel stuff works too.
>
> I'm going to cancel this feature request as it looks to me like we
> already have this. Feel free to keep replying though. I'll reopen this
> as a bug if you find anything!
>
> Canceled.