emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Org-Mode and Mac OS X advice


From: Alan Schmitt
Subject: Re: [O] Org-Mode and Mac OS X advice
Date: Thu, 26 Mar 2015 14:57:40 +0100
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.4.90 (darwin)

On 2015-03-26 14:50, Bernd Haug <address@hidden> 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

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