From 88454f58ec6cfa746ad55748da13a09a3d8f39a8 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sun, 19 Mar 2017 22:51:29 -0400 Subject: [PATCH] core-os: don't cache exec-path too aggressively --- core/core-os.el | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/core/core-os.el b/core/core-os.el index fd47694bc..aec485766 100644 --- a/core/core-os.el +++ b/core/core-os.el @@ -31,11 +31,12 @@ (cond ((display-graphic-p) ;; `exec-path-from-shell' is slow, so bring out the cache (setq exec-path - (or (persistent-soft-fetch 'exec-path "emacs") - (and (require 'exec-path-from-shell nil t) - (progn (exec-path-from-shell-initialize) - (persistent-soft-store 'exec-path exec-path "emacs"))) - exec-path))) + (eval-when-compile + (require 'exec-path-from-shell nil t) + (nconc exec-path-from-shell-variables '("GOPATH" "GOROOT" "PYTHONPATH")) + (exec-path-from-shell-initialize) + (persistent-soft-store 'exec-path exec-path "emacs") + exec-path))) (t (when (require 'osx-clipboard nil t) (osx-clipboard-mode +1))))