Skip to main content
Added sample code
Source Link
Steven
  • 209
  • 4
  • 6

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my exec-path, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

Edit: Here's the code I use

;; I set this at the beginning of my init.el for other mac specific settings (defconst *is-a-mac* (eq system-type 'darwin)) ;; Later on, after loading exec-path-from-shell package (if *is-a-mac* (add-hook 'after-init-hook 'exec-path-from-shell-initialize)) 

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my exec-path, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my exec-path, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

Edit: Here's the code I use

;; I set this at the beginning of my init.el for other mac specific settings (defconst *is-a-mac* (eq system-type 'darwin)) ;; Later on, after loading exec-path-from-shell package (if *is-a-mac* (add-hook 'after-init-hook 'exec-path-from-shell-initialize)) 
added 5 characters in body
Source Link
Steven
  • 209
  • 4
  • 6

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my initexec-path, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my init, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my exec-path, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

Added more details
Source Link
Steven
  • 209
  • 4
  • 6

I ended up just installingrecently started using emacs outside of the exec-path-from-shell packageterminal which was causing me some PATH issues. I had tried setting it myself butby adding (getenv "PATH") to my init, among other things that ultimately never worked.

I figuredended up installing the package was cleaner than having bunch of extra lines in my configsexec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

I ended up just installing the exec-path-from-shell package. I tried setting it myself but I figured installing the package was cleaner than having bunch of extra lines in my configs.

I recently started using emacs outside of the terminal which was causing me some PATH issues. I had tried setting it by adding (getenv "PATH") to my init, among other things that ultimately never worked.

I ended up installing the exec-path-from-shell package via melpa. It works by using your $SHELL environment variable to ask your shell to print out your $PATH and copying the result.

Source Link
Steven
  • 209
  • 4
  • 6
Loading