purcell / envrc

Emacs support for direnv which operates buffer-locally
378 stars 35 forks source link

Add option to hide lighter if no envrc is detected #21

Closed matthewbauer closed 3 years ago

matthewbauer commented 3 years ago

This only includes the lighter when envrc is actually active. This behavior can be turned on by setting envrc-hide-lighter-on-none. The benefit is to avoid littering the mode line.

purcell commented 3 years ago

Hey, thanks for this! I took a different route in the end, for a little more flexibility: https://github.com/purcell/envrc/pull/21/commits/17b8d6fc71e9fcd1673ce2b74a67a4be3084e757

In short, for your use case you should be able to (setq envrc-none-lighter nil) now.