From aa2ccced10ca63a6a53021728da7fbc523e4943d Mon Sep 17 00:00:00 2001 From: syl20bnr Date: Wed, 8 Jul 2015 01:06:38 -0400 Subject: [PATCH] shell layer: disable auto-jump to prompt when em-smart is enabled --- contrib/shell/packages.el | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/contrib/shell/packages.el b/contrib/shell/packages.el index 46ced188d..840d09b28 100644 --- a/contrib/shell/packages.el +++ b/contrib/shell/packages.el @@ -63,8 +63,12 @@ (defun spacemacs//init-eshell () "Stuff to do when enabling eshell." (setq pcomplete-cycle-completions nil) - (add-hook 'evil-insert-state-entry-hook - 'spacemacs//eshell-auto-end nil t) + (unless shell-enable-smart-eshell + ;; we don't want auto-jump to prompt when smart eshell is enabled. + ;; Idea: maybe we could make auto-jump smarter and jump only if the + ;; point is not on a prompt line + (add-hook 'evil-insert-state-entry-hook + 'spacemacs//eshell-auto-end nil t)) (when (configuration-layer/package-usedp 'semantic) (semantic-mode -1))) (add-hook 'eshell-mode-hook 'spacemacs//init-eshell))