branch: elpa/guru-mode commit adf92d909a173c67849e66ca8f0af01aecfcc3c4 Author: Bozhidar Batsov <bozhi...@batsov.com> Commit: Bozhidar Batsov <bozhi...@batsov.com>
docs & code clean-up --- README.md | 57 ++++++++++++++++++++++++++++++++++++++++++++------------- guru-mode.el | 13 +++++++------ 2 files changed, 51 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 2de0cfc..98f1579 100644 --- a/README.md +++ b/README.md @@ -10,20 +10,7 @@ folder `~/.emacs.d/vendor`: ```lisp (add-to-list 'load-path "~/emacs.d/vendor") -``` - -You can enable `guru-mode` globally like this: - -```lisp (require 'guru-mode) -(guru-global-mode +1) ;; to enable in all buffers -``` - -Most likely you'd like to enable `guru-mode` only in specific modes -(like `prog-mode` in Emacs 24): - -```lisp -(add-hook 'prog-mode-hook (lambda () (guru-mode +1))) ``` ## Marmalade @@ -42,3 +29,47 @@ you can install guru-mode from the [MELPA](http://melpa.milkbox.net/) repository [Emacs Prelude](https://github.com/bbatsov/prelude). If you're a Prelude user - `guru-mode` is already properly configured and ready for action. + +# Usage + +You can enable `guru-mode` globally like this: + +```lisp +(guru-global-mode +1) +``` + +Most likely you'd like to enable `guru-mode` only in specific modes +(like `prog-mode` in Emacs 24): + +```lisp +(add-hook 'prog-mode-hook 'turn-on-guru-mode) +``` + +# Share the knowledge + +[WikEmacs](http://wikemacs.org) collects useful resources for working +with GNU Emacs. Please, take the time to peruse and improve them as +you accumulate knowledge about Emacs. Prelude makes this especially +easy, since it bundles +[MediaWiki support](http://wikemacs.org/wiki/Mediawiki.el) + the +settings required to access WikEmacs right away. + +# Known issues + +Check out the project's +[issue list](https://github.com/bbatsov/guru-mode/issues?sort=created&direction=desc&state=open) +a list of unresolved issues. By the way - feel free to fix any of them +and send me a pull request. :-) + +# Contributors + +Here's a [list](https://github.com/bbatsov/guru-mode/contributors) of all the people who have contributed to the +development of guru-mode. + +# Bugs & Improvements + +Bug reports and suggestions for improvements are always +welcome. GitHub pull requests are even better! :-) + +Cheers,<br/> +Bozhidar diff --git a/guru-mode.el b/guru-mode.el index da93037..7218e59 100644 --- a/guru-mode.el +++ b/guru-mode.el @@ -68,23 +68,24 @@ (define-key guru-mode-map (read-kbd-macro (first cell)) (guru-rebind (first cell) (rest cell)))) -(defun guru-on () - "Enable Guru." +(defun turn-on-guru-mode () + "Enable Guru mode." (guru-mode +1)) -(defun guru-off () - "Disable Guru." +(defun turn-off-guru-mode () + "Disable Guru mode." (guru-mode -1)) ;;;###autoload -(define-minor-mode guru-mode "A minor mode that teaches to help you use Emacs the way it was intended to be used." +(define-minor-mode guru-mode + "A minor mode that teaches you to use Emacs effectively." :lighter " guru" :keymap guru-mode-map :group 'guru) ;; define global minor mode ;;;###autoload -(define-globalized-minor-mode guru-global-mode guru-mode guru-on) +(define-globalized-minor-mode guru-global-mode guru-mode turn-on-guru-mode) (provide 'guru-mode) ;;; guru-mode.el ends here