forked from naiquevin/sphinx-doc.el
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Readme, comments, demo and add change log
- Loading branch information
Showing
4 changed files
with
69 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
Changes | ||
======= | ||
|
||
0.2.0 | ||
----- | ||
|
||
This is almost a rewrite of the earlier version primarily for the | ||
following: | ||
|
||
* Support for updating existing docstring | ||
* Defined as a minor mode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,34 +2,59 @@ | |
;;; functions. | ||
|
||
;; Author: Vineet Naik <[email protected]> | ||
;; Created: 14th October 2013 | ||
;; Created on: 14th October 2013 | ||
;; URL: https://github.com/naiquevin/sphinx-doc.el | ||
;; Version: 0.2.0 | ||
|
||
;; License: MIT <http://opensource.org/licenses/MIT> | ||
;; This program is *not* a part of emacs and is provided under the MIT | ||
;; License (MIT) <http://opensource.org/licenses/MIT> | ||
;; | ||
;; Copyright (c) 2013 <[email protected]> | ||
;; | ||
;; Permission is hereby granted, free of charge, to any person | ||
;; obtaining a copy of this software and associated documentation | ||
;; files (the "Software"), to deal in the Software without | ||
;; restriction, including without limitation the rights to use, copy, | ||
;; modify, merge, publish, distribute, sublicense, and/or sell copies | ||
;; of the Software, and to permit persons to whom the Software is | ||
;; furnished to do so, subject to the following conditions: | ||
;; | ||
;; The above copyright notice and this permission notice shall be | ||
;; included in all copies or substantial portions of the Software. | ||
;; | ||
;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
;; NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS | ||
;; BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN | ||
;; ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
;; CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
;; SOFTWARE. | ||
|
||
;;; Commentary: | ||
|
||
;; This file just provides a function `sphinx-doc` that can be used to | ||
;; generate skeleton of docstrings for Python functions. The structure | ||
;; of the docstring is according to Sphinx documentation generator | ||
;; | ||
;; This file provides a minor mode for inserting docstring skeleton | ||
;; for Python functions and methods. The structure of the docstring is | ||
;; as per the requirements of the Sphinx documentation generator | ||
;; <http://sphinx-doc.org/index.html> | ||
|
||
;;; Installation: | ||
|
||
;; Copy this file somewhere in your path and add the following lines | ||
;; to your .emacs (or the equivalent config file) | ||
;; | ||
;; (require 'sphinx-doc) | ||
;; This package is yet to be published on MELPA. Until then, copy this | ||
;; file somewhere in your path and add the following lines to your | ||
;; .emacs (or the equivalent config file) | ||
;; | ||
;; (add-hook 'python-mode-hook (lambda () (local-set-key (kbd "C-c M-d") #'sphinx-doc))) | ||
;; (add-hook 'python-mode-hook (lambda () (require 'sphinx-doc))) | ||
;; | ||
;; This will bind the function `sphinx-doc` to `C-c M-d`. Choose this | ||
;; as per your liking. | ||
;; This will bind the interactive function `sphinx-doc` to `C-c | ||
;; M-d`. | ||
|
||
;;; Usage: | ||
;; | ||
;; Inside a Python file, move the cursor to some function/method | ||
;; definition and hit `C-c M-d` | ||
|
||
;; In a Python file, move the cursor the function definition and type | ||
;; `C-c M-d` (or the key binding you have chosen). Alternatively, | ||
;; execute the function using `M-x sphinx-doc RET` | ||
;;; code begins here | ||
|
||
;; include libs | ||
|
||
|
@@ -392,4 +417,4 @@ | |
|
||
(provide 'sphinx-doc) | ||
|
||
;; sphinx-doc.el ends | ||
;;; code ends here |