From: Peng Li Date: Sat, 2 Jul 2016 13:19:24 +0000 (+0800) Subject: emacs - fix bug sd/eshell-here X-Git-Url: http://47.100.26.94:8080/?a=commitdiff_plain;h=225141d6f7444d2bc6cbff3b3998d463e6ecacb9;p=dotfiles.git emacs - fix bug sd/eshell-here --- diff --git a/emacs.d/config.org b/emacs.d/config.org index 1b39c87..90b3ad1 100644 --- a/emacs.d/config.org +++ b/emacs.d/config.org @@ -1257,13 +1257,11 @@ Quickly start eshll in split window below, refer [[http://www.howardism.org/Tech (progn (split-window-vertically (- (/ (window-total-height) 3))) (other-window 1) - (unless (get-buffer eshell-buffer-name) + (unless (and (boundp 'eshell-buffer-name) (get-buffer eshell-buffer-name)) (eshell)) (switch-to-buffer eshell-buffer-name) (goto-char (point-max)) (eshell-kill-input) - (message "wowo is %s" default-directory) - (message "wowo is %s" (file-name-directory (buffer-name))) (insert (format "cd %s" default-directory)) (eshell-send-input))))