summaryrefslogtreecommitdiff
path: root/lisp/eshell/em-script.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/eshell/em-script.el')
-rw-r--r--lisp/eshell/em-script.el12
1 files changed, 6 insertions, 6 deletions
diff --git a/lisp/eshell/em-script.el b/lisp/eshell/em-script.el
index b8a5ecd9002..4a3b84e10e3 100644
--- a/lisp/eshell/em-script.el
+++ b/lisp/eshell/em-script.el
@@ -23,8 +23,7 @@
;;; Code:
-(require 'eshell)
-(require 'esh-opt)
+(require 'esh-mode)
;;;###autoload
(progn
@@ -57,11 +56,11 @@ This includes when running `eshell-command'."
;;; Functions:
-(defun eshell-script-initialize ()
+(defun eshell-script-initialize () ;Called from `eshell-mode' via intern-soft!
"Initialize the script parsing code."
(make-local-variable 'eshell-interpreter-alist)
(setq eshell-interpreter-alist
- (cons (cons #'(lambda (file args)
+ (cons (cons #'(lambda (file _args)
(string= (file-name-nondirectory file)
"eshell"))
'eshell/source)
@@ -73,13 +72,14 @@ This includes when running `eshell-command'."
;; to ruin it for other modules
(let (eshell-inside-quote-regexp
eshell-outside-quote-regexp)
- (and (not eshell-non-interactive-p)
+ (and (not (bound-and-true-p eshell-non-interactive-p))
eshell-login-script
(file-readable-p eshell-login-script)
(eshell-do-eval
(list 'eshell-commands
(catch 'eshell-replace-command
- (eshell-source-file eshell-login-script))) t))
+ (eshell-source-file eshell-login-script)))
+ t))
(and eshell-rc-script
(file-readable-p eshell-rc-script)
(eshell-do-eval