Integrate helpful into doom/describe-active-minor-mode

This commit is contained in:
Henrik Lissner 2019-10-26 04:20:17 -04:00
parent c6c8a33eb6
commit 1dd73b7486
No known key found for this signature in database
GPG Key ID: 5F6C0EA160557395

View File

@ -96,10 +96,13 @@ the current major-modea.")
selection of all minor-modes, active or not."
(interactive
(list (completing-read "Minor mode: " (doom-active-minor-modes))))
(describe-minor-mode-from-symbol
(cond ((stringp mode) (intern mode))
((symbolp mode) mode)
((error "Expected a symbol/string, got a %s" (type-of mode))))))
(let ((symbol
(cond ((stringp mode) (intern mode))
((symbolp mode) mode)
((error "Expected a symbol/string, got a %s" (type-of mode))))))
(if (fboundp symbol)
(helpful-function symbol)
(helpful-variable symbol))))
;;;###autoload
(defun doom/describe-symbol (symbol)