patch-eshell-inside-emacs.el 353 B

12345678910
  1. ;;; Reported upstream, see #39596.
  2. (defun ambrevar/set-inside-emacs ()
  3. "Export INSIDE_EMACS just like M-x shell does.
  4. This is useful for programs like Guix that take provisions for Emacs."
  5. (setenv "INSIDE_EMACS" (format "%s;%s" emacs-version "eshell")))
  6. (add-hook 'eshell-mode-hook 'ambrevar/set-inside-emacs)
  7. (provide 'patch-eshell-inside-emacs)