0

when I type in emacs shell and tab to complete, a completion minibuffer shows up and list the possible completions like this:

Click <mouse-2> on a completion to select it.
In this buffer, type RET to select the completion near point.

Possible completions are:
CLUTTER_IM_MODULE   DBUS_SESSION_BUS_ADDRESS    DEFAULTS_PATH

I was able to remove first two lines by setting (setq completion-show-help nil). but is it possible to get rid of possible completions are:? I just want a little bit of cleanness.

Rorschach
  • 31,301
  • 5
  • 78
  • 129
EAGLE
  • 3
  • 2
  • Took a look at the code: that's hardwired. Only way to get rid of it is to modify the code. – NickD Oct 05 '19 at 03:07

1 Answers1

0

One simple hack around that message not being customizable is to just erase that line from the output buffer after display-completion-list runs (assuming you have already set completion-show-help to nil),

(define-advice display-completion-list (:after (&rest r) "remove-msg")
  (with-current-buffer standard-output
    (goto-char (point-min))
    (when (looking-at-p "Possible completions.*")
      (delete-region (line-beginning-position) (line-beginning-position 2)))))
Rorschach
  • 31,301
  • 5
  • 78
  • 129