Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

defaultxr/eshell-eldoc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Eshell-Eldoc

Eshell-Eldoc is eldoc-mode support for eshell.

NOTE: I no longer use nor develop this library; I recommend esh-help instead, as it is available from MELPA and has all of the features of this library and more.

Eshell-Eldoc first checks for elisp functions named by eshell’s input and uses Emacs’ built in eldoc functionality to display documentation if one is found.

If no elisp or eshell function with the name is found, the whatis(1) command is used to get a description of a shell command of the input text. Caching is built in to the whatis lookup, so slowdown should be minimal for repeatedly-typed inputs.

Installation

Available via MELPA soon!

Once it is, simply install it, and then evaluate and add the following to your init file:

(add-hook 'eshell-mode-hook 'eshell-eldoc-enable-for-buffer)

Note that for whatis to actually return results, you may need to run the mandb command as root to regenerate the manpage index.

You may need to run this command again if a newly-installed program isn’t being picked up. And since eshell-eldoc caches the results from whatis (including empty results), you may also need to clear the cache with the eshell-eldoc-clear-cache command, or restart Emacs.

Future

  • It would be nice if it were possible to make this package automatically enable itself (i.e. without requiring the user to use add-hook). I’m not sure if this is possible.

Similar Libraries

  • esh-help - provides similar eldoc support for eshell and external, but gives the “SYNOPSIS” from a command’s manpage instead of the summary from whatis.
  • emacs-fish-completion - for Fish shell-like command completion in eshell.

Releases

No releases published

Packages

No packages published