tools/direnv: replace direnv package with envrc

wbolster/emacs-direnv uses an approach that mutates global state,
allowing a direnv to bleed into unrelated buffers and contexts. For this
to work it must rereads the direnv every time you switch buffers, which
can be very slow.

purcell/envrc, on the other hand, makes env state buffer-local, so the
direnv only needs to be read once, when a is first initialized. This is
faster and less error prone. However, it's necessary to manually reload
the direnv if you've changed your .envrc outside of Emacs (with `M-x
envrc-reload` or `M-x envrc-reload-all`).
This commit is contained in:
Henrik Lissner 2020-08-21 02:34:07 -04:00
parent e54bb170c3
commit 06c404ecb1
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
3 changed files with 24 additions and 15 deletions

View file

@ -34,7 +34,7 @@ direnv and then made available to the current shell.
This module provides no flags.
** Plugins
+ [[https://github.com/wbolster/emacs-direnv][direnv]]
+ [[https://github.com/purcell/envrc][envrc]]
** Hacks
+ Normally, the direnv environment is updated on ~post-command-hook~. We've