Skip to content

minemacs/consult-dash

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Consult interface to dash docs

consult-dash provides a consult interface to dash documentation. The easiest way to install is to add consult-dash.el to your emacs lisp path.

The only interface provided is the function consult-dash, which should be bound to a key sequence. If the default search term should be derived from the symbol at point, please use the normal consult method to customize consult-dash prompts:

(consult-customize consult-dash :initial (thing-at-point 'symbol))

Support for embark is automatically enabled when embark is loaded.

The following is an example use-package declaration:

(use-package consult-dash
  :bind (("M-s d" . consult-dash))
  :config
  ;; Use the symbol at point as initial search term
  (consult-customize consult-dash :initial (thing-at-point 'symbol)))

Buffer-local values of docsets to search can be set by customizing the buffer-local variable consult-dash-docsets in a mode hook. The following is an example intended to placed inside a python mode hook:

(when (functionp 'consult-dash)
  (setq-local consult-dash-docsets '("Python 2" "Python 3" "NumPy")))

Please see dash documentation for more details on installing docsets.

Known limitations

The current implementation works only on Unix-like systems, since it uses a shell command sequence to concatenate search commands for each docset. Patches to support other systems, or a better method for searching in sequence, are welcome. Please see the functions consult-dash--builder-one-docset and consult-dash--builder in the source for details.

About

Mirror of consult-dash

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors