From 7cf8301ea9d471e03c5d284518fa84d41fb5822a Mon Sep 17 00:00:00 2001 From: Rahul Saxena Date: Sun, 13 May 2012 11:25:36 -0600 Subject: [PATCH] OSX: Add path support for macports binaries macports binaries are located at /opt/local/bin and sbin --- prelude/prelude-osx.el | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/prelude/prelude-osx.el b/prelude/prelude-osx.el index 4074ae2..e08a816 100644 --- a/prelude/prelude-osx.el +++ b/prelude/prelude-osx.el @@ -1,7 +1,10 @@ ;; On OS X Emacs doesn't use the shell PATH if it's not started from -;; the shell. If you're using homebrew modifying the PATH is essential. -(push "/usr/local/bin" exec-path) -(setenv "PATH" (concat "/usr/local/bin:" (getenv "PATH"))) +;; the shell. +;; If you're using homebrew or port, modifying the PATH is essential. +(let (osx-paths) + (dolist (path '("/usr/local/bin" "/opt/local/bin" "/opt/local/sbin") (setenv "PATH" (concat osx-paths (getenv "PATH")))) + (push path exec-path) + (setq osx-paths (concat (concat path ":") osx-paths)))) ;; Emacs users obviously have little need for Command and Option keys, ;; but they do need Meta and Super