From 9def9ca4e7912390ad93ae48169e809082821a1c Mon Sep 17 00:00:00 2001 From: Dimitri Lozeve Date: Wed, 14 Feb 2024 10:49:06 +0100 Subject: [PATCH] Speed up exec-path-from-shell Moved PATH settings to .zshenv to allow for non-interactive shell loading. --- init.el | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/init.el b/init.el index bf9e536..a426e94 100644 --- a/init.el +++ b/init.el @@ -143,11 +143,13 @@ (use-package exec-path-from-shell :straight t + :init + (setq exec-path-from-shell-arguments '("-l")) :config (when (memq window-system '(mac ns x pgtk)) - (exec-path-from-shell-initialize) - (exec-path-from-shell-copy-env "SSH_AUTH_SOCK") - (exec-path-from-shell-copy-env "SSH_AGENT_PID"))) + (dolist (var '("SSH_AUTH_SOCK" "SSH_AGENT_PID")) + (add-to-list 'exec-path-from-shell-variables var)) + (exec-path-from-shell-initialize))) ;;; Menus and completion