Skip to content

Commit

Permalink
Fix envrc-global-mode with absolute direnv path
Browse files Browse the repository at this point in the history
Since e0e8496, `envrc-global-mode` no
longer works when `envrc-direnv-executable` is customized.

Since it always checks for "direnv", it won't work if direnv is not on
the path or if the direnv executable has a different name.
  • Loading branch information
accelbread committed May 3, 2024
1 parent 8571bf9 commit 7d0c942
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion envrc.el
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ e.g. (define-key envrc-mode-map (kbd \"C-c e\") \\='envrc-command-map)"
;;;###autoload
(define-globalized-minor-mode envrc-global-mode envrc-mode
(lambda () (when (and (not (minibufferp)) (not (file-remote-p default-directory))
(executable-find "direnv"))
(executable-find envrc-direnv-executable))
(envrc-mode 1))))

(defface envrc-mode-line-on-face '((t :inherit success))
Expand Down

0 comments on commit 7d0c942

Please sign in to comment.