How can I get the python document in Emacs.I list two ways.
1、Using the man
command?But I don't know where to download man
file.
2、Some people suggest me to use dash in Emacs.What's dash.I can't find dash-mode in Emacs.
How can I get the python document in Emacs.I list two ways.
1、Using the man
command?But I don't know where to download man
file.
2、Some people suggest me to use dash in Emacs.What's dash.I can't find dash-mode in Emacs.
Both Elpy and Anaconda-mode have ways of looking up Python documentation:
In Elpy: https://elpy.readthedocs.io/en/latest/ide.html#command-elpy-doc
In Anaconda-mode: https://github.com/proofit404/anaconda-mode#eldoc
I have used both these packages in the past, and both are great!
I generated the Python docs in info format and use the info reader in Emacs. The Python documentation is spread out and the info reader is great at bringing those disparate pieces together.
The first step is to get a copy of the Python documentation in info format. The Python project does a great job making it easy to generate it (the info files themselves probably aren't distributed because the rst-to-info conversion isn't perfect). I detailed how to generate the Python docs in info yourself in this response. The process and the resulting info files are also hosted here.
To read an info file in Emacs, use C-u C-h i
to be prompted for the file path. If you have the info file installed on your system (detailed here), you can use C-u 2 C-h i
(or any other number, 3, 4, 5, etc.) to open a separate info buffer. This allows you to have multiple copies open side by side.
You can search the entire manual forward using C-s
and backward with C-r
. Use m
to goto a menu item; press tab
to see completions. Similarly, use g
to jump to a node. You can press tab
on a page to move the cursor the the next link. Use, l
for the last page, u
to move up a node, t
to go to the "top" of the manual. Running info-apropos
will generate a menu of all places in the manual that contain a search term. Execute M-: (Info-goto-node "(info)")
to visit the Emacs info manual (which is somewhat different from the standalone info reader). The info reader has a lot of helpful commands!