Giter Site home page Giter Site logo

helpful's Introduction

Helpful Coverage Status MELPA

Helpful is an alternative to the built-in Emacs help that provides much more contextual information.

screenshot

Usage

Install from MELPA, then call one of the following commands:

  • helpful-callable
  • helpful-function
  • helpful-macro
  • helpful-command
  • helpful-key
  • helpful-variable
  • helpful-at-point

If you want to replace the default Emacs help keybindings, you can do so:

;; Note that the built-in `describe-function' includes both functions
;; and macros. `helpful-function' is functions only, so we provide
;; `helpful-callable' as a drop-in replacement.
(global-set-key (kbd "C-h f") #'helpful-callable)

(global-set-key (kbd "C-h v") #'helpful-variable)
(global-set-key (kbd "C-h k") #'helpful-key)
(global-set-key (kbd "C-h x") #'helpful-command)

I also recommend the following keybindings to get the most out of helpful:

;; Lookup the current symbol at point. C-c C-d is a common keybinding
;; for this in lisp modes.
(global-set-key (kbd "C-c C-d") #'helpful-at-point)

;; Look up *F*unctions (excludes macros).
;;
;; By default, C-h F is bound to `Info-goto-emacs-command-node'. Helpful
;; already links to the manual, if a function is referenced there.
(global-set-key (kbd "C-h F") #'helpful-function)

Ivy users can use Helpful with counsel commands:

(setq counsel-describe-function-function #'helpful-callable)
(setq counsel-describe-variable-function #'helpful-variable)

Features

Source code

screenshot

Helpful will try really hard to show the source code. It shows the source code for interactively defined functions (unlike the built-in Help) and falls back to the raw sexp if no source is available.

View Callers

screenshot

Helpful will show you where a function is being called!

Prettier Docstrings

screenshot

Docstrings in helpful:

  • Highlight the summary (the first sentence)
  • Include cross-references to other functions/variables
  • Linkify references to Info nodes
  • Hide superfluous punctuation

screenshot

If a symbol is also documented in the Info manual, helpful will provide a link to the relevant section too.

Symbol Properties

screenshot

Helpful will show you the properties that have been applied to the current symbol. This provides visibility of features like edebug or byte-code optimisation.

Helpful will also highlight any symbol aliases.

Describe Commands

Helpful provides a separate helpful-command function, for when you just want to view interactive functions.

View Keymaps

screenshot

Helpful displays any keybindings that apply to interactive functions.

Integrated Tooling

screenshot

You can trace, debug or disassemble functions from inside Helpful. This is discoverable and doesn't require memorisation of commands.

Aliases

screenshot

If a function has multiple aliases in Emacs, Helpful will show all of the aliases defined.

Inspirations

This project has been heavily influenced by:

License

GPLv3+.

I am providing code in the repository to you under an open source license. Because this is my personal repository, the license you receive to my code is from me and not my employer.

helpful's People

Contributors

wilfred avatar nickdrozd avatar narendraj9 avatar damiencassou avatar kisaragi-hiu avatar alexander-miller avatar nagy avatar sound-logic avatar nbfalcon avatar vermiculus avatar xeals avatar yuhan0 avatar rhaps0dy avatar celeritascelery avatar xuchunyang avatar dakra avatar danielmartin avatar d125q avatar davidshepherd7 avatar erikarvstedt avatar hraban avatar iwahbe avatar jcs090218 avatar wyuenho avatar kljohann avatar tarsius avatar pythonnut avatar lebensterben avatar mekeor avatar nbarrientos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.