;;; -*- lexical-binding: t; -*-

(require 'syd/base)

(use-package envrc
  ;; REVIEW: Can we load this any later/better?
  :hook (on-first-file . envrc-global-mode)
  :general
  (:prefix-map 'syd-leader-file-env-map
   "a" #'envrc-allow
   "r" #'envrc-reload)
  (:keymaps 'syd-leader-file-map
   "e" `("Environment" . ,syd-leader-file-env-map))
  :config
  (syd-push shackle-rules
            `("*envrc*" :custom ,#'ignore)))

(provide 'syd/direnv)
