aboutsummaryrefslogtreecommitdiff
path: root/Emacs/.config/emacs
diff options
context:
space:
mode:
Diffstat (limited to 'Emacs/.config/emacs')
-rw-r--r--Emacs/.config/emacs/elisp/eshell-additions.el10
1 files changed, 6 insertions, 4 deletions
diff --git a/Emacs/.config/emacs/elisp/eshell-additions.el b/Emacs/.config/emacs/elisp/eshell-additions.el
index 0abaf6a..0436851 100644
--- a/Emacs/.config/emacs/elisp/eshell-additions.el
+++ b/Emacs/.config/emacs/elisp/eshell-additions.el
@@ -50,13 +50,15 @@
(eshell/cd wrapped-dir)))
;; Additional functions
-(defun +eshell/at-cwd ()
- "Open an instance of eshell at the current working directory."
- (interactive)
+(defun +eshell/at-cwd (&optional arg)
+ "Open an instance of eshell at the current working directory.
+
+Pass argument to `+eshell/open'."
+ (interactive "P")
(let ((dir (if buffer-file-name
(file-name-directory buffer-file-name)
default-directory))
- (buf (eshell)))
+ (buf (+eshell/open arg)))
(with-current-buffer buf
(eshell/cd dir)
(eshell-send-input))))