From c0f601721c4b30f9d45100fcbd567feae2d5ff0b Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sat, 16 Jun 2018 16:37:43 +0200 Subject: [PATCH] emacs/eshell: fix pcomplete+ivy/helm integration Use ivy/helm instead of the popup at the bottom. --- modules/emacs/eshell/autoload/eshell.el | 8 ++++++++ modules/emacs/eshell/config.el | 1 + 2 files changed, 9 insertions(+) diff --git a/modules/emacs/eshell/autoload/eshell.el b/modules/emacs/eshell/autoload/eshell.el index e2ff5f261..d24488d40 100644 --- a/modules/emacs/eshell/autoload/eshell.el +++ b/modules/emacs/eshell/autoload/eshell.el @@ -125,6 +125,14 @@ module to be loaded." (insert command) (eshell-send-input nil t))) +;;;###autoload +(defun +eshell/pcomplete () + "Use pcomplete with completion-in-region backend instead of popup window at +bottom. This ties pcomplete into ivy or helm, if they are enabled." + (interactive) + (require 'pcomplete) + (pcomplete-std-complete)) + ;; ;; Hooks diff --git a/modules/emacs/eshell/config.el b/modules/emacs/eshell/config.el index 8c4108b3e..3e7e1156c 100644 --- a/modules/emacs/eshell/config.el +++ b/modules/emacs/eshell/config.el @@ -63,6 +63,7 @@ redefines its keys every time `eshell-mode' is enabled." "d" #'+eshell/evil-delete "D" #'+eshell/evil-delete-line) (evil-define-key* 'insert eshell-mode-map + [tab] #'+eshell/pcomplete "\C-d" #'+eshell/quit-or-delete-char "\C-p" #'eshell-previous-input "\C-n" #'eshell-next-input))