Variable: eshell-save-history-on-exit
eshell-save-history-on-exit is a customizable variable defined in
em-hist.el.gz.
Value
t
Documentation
Determine if history should be automatically saved.
History is always preserved after sanely exiting an Eshell buffer.
However, when Emacs is being shut down, this variable determines
whether to prompt the user.
If set to nil, it means never save history on termination of Emacs.
If set to ask, ask if any Eshell buffers are open at exit time.
If set to t, history will always be saved, silently.
Source Code
;; Defined in /usr/src/emacs/lisp/eshell/em-hist.el.gz
(defcustom eshell-save-history-on-exit t
"Determine if history should be automatically saved.
History is always preserved after sanely exiting an Eshell buffer.
However, when Emacs is being shut down, this variable determines
whether to prompt the user.
If set to nil, it means never save history on termination of Emacs.
If set to `ask', ask if any Eshell buffers are open at exit time.
If set to t, history will always be saved, silently."
:type '(choice (const :tag "Never" nil)
(const :tag "Ask" ask)
(const :tag "Always save" t)))