On 2015-03-26 14:50, Bernd Haug <bernd.h...@xaidat.com> writes:

> Alternatively:
>
> • Configure your path in your user's launchd config so that the whole
> session has LaTeX in your path
> • Modify your shell environment and just launch Emacs from the shell.
> The binary would then be /Applications/Emacs.app/Contents/MacOS/Emacs

I'm using this nice trick (passed to me by a colleague) that sets the
environment variables and path to be the same in zsh and emacs (launched
From the GUI).

#+begin_src emacs-lisp
(let ((vars (split-string-and-unquote (shell-command-to-string ". ~/.zshrc; 
export") "\n")))
  (mapcar (lambda (X) (let ((var_val (split-string-and-unquote X "=")))
                        (setenv (car var_val) (cadr var_val)))) vars)
  (setq exec-path 
        (append
         (split-string-and-unquote (getenv "PATH") ":")
         exec-path)))
#+end_src

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7

Attachment: signature.asc
Description: PGP signature

Reply via email to