我还没升级 macOS,不过我没依赖 Mac Port 的这个特性,而是自己手动设置的
;; [[https://emacs-china.org/t/topic/5507][Mac 下给 Emacs 设置 PATH 和 exec-path - Emacs-general - Emacs China]]
;; NOTE: When PATH is changed, run the following command
;; $ sh -c 'printf "%s" "$PATH"' > .path
(when *is-mac*
(condition-case err
(let ((path (with-temp-buffer
(insert-file-contents-literally "~/.path")
(buffer-string))))
(setenv "PATH" path)
(setq exec-path (append (parse-colon-path path) (list exec-directory))))
(error (warn "%s" (error-message-string err)))))
这样完全不用运行个 Shell 来获得 PATH。