Updating Doom Emacs.

This commit is contained in:
Derek Taylor
2020-06-19 22:43:40 -05:00
parent 0f664d532a
commit a5c86c514a
453 changed files with 13527 additions and 12455 deletions

View File

@@ -7,7 +7,6 @@
- [[#description][Description]]
- [[#module-flags][Module Flags]]
- [[#plugins][Plugins]]
- [[#hacks][Hacks]]
- [[#prerequisites][Prerequisites]]
- [[#language-server-protocol-support][Language Server Protocol Support]]
- [[#features][Features]]
@@ -26,6 +25,8 @@ Adds Python support to Doom Emacs.
+ ~+lsp~ Language Server Protocol support
+ ~+pyenv~ Python virtual environment support via [[https://github.com/pyenv/pyenv][pyenv]]
+ ~+conda~ Python virtual environment support via [[https://conda.io/en/latest/][Conda]]
+ ~+poetry~ Python packaging, dependency management, and virtual environment
support via [[https://python-poetry.org/][Poetry]]
+ ~+cython~ Cython files support via [[https://github.com/cython/cython/blob/master/Tools/cython-mode.el][Cython-mode]]
** Plugins
@@ -42,17 +43,14 @@ Adds Python support to Doom Emacs.
+ [[https://github.com/necaris/conda.el][conda]]*
+ ~+pyenv~
+ [[https://github.com/pythonic-emacs/pyenv-mode][pyenv]]*
+ ~+poetry~
+ [[https://github.com/galaunay/poetry.el][poetry]]*
+ ~+lsp~ and ~:tools lsp~
+ [[https://github.com/emacs-lsp/lsp-mode][lsp]]
+ [[https://github.com/emacs-lsp/lsp-python-ms][lsp-python-ms]]*
+ ~+cython~
+ [[https://github.com/cython/cython/blob/master/Tools/cython-mode.el][Cython-mode]]
+ ~:tools flycheck~ [[https://github.com/lbolla/emacs-flycheck-cython/tree/master][Flycheck-cython]]
** Hacks
+ As per our "your system your rules" mantra, lsp-python-ms has been modified to
*not* automatically install its server if it cannot find it. Install it with
~M-x lsp-python-ms-setup~.
+ ~:checkers syntax~ [[https://github.com/lbolla/emacs-flycheck-cython/tree/master][Flycheck-cython]]
* Prerequisites
This module has no direct prerequisites. Here are some of its soft dependencies.
@@ -73,22 +71,26 @@ This module has no direct prerequisites. Here are some of its soft dependencies.
+ Python virtual environments install instructions at:
+ [[https://github.com/pyenv/pyenv][pyenv]]
+ [[https://conda.io/en/latest/][Conda]]
+ [[https://python-poetry.org/][Poetry]]
+ ~pipenv~ requires [[https://pipenv.readthedocs.io/en/latest/][pipenv]]
+ ~cython~ requires [[https://cython.org/][Cython]]
** Language Server Protocol Support
Requires the ~+lsp~ flag and ~:tools lsp~ module to be enabled.
By default LSP will use Microsoft's language server if installed.
This module must be enabled with the =+lsp= flag, and the =:tools lsp= module
must be enabled. LSP will try pyls then mspyls; the first that is available.
To install the language server:
~M-x lsp-python-ms-setup~
To update the server:
~M-x lsp-python-ms-update-server~
*To use [[https://pypi.org/project/python-language-server/][Python Language Server]] (pyls)* install it with ~pip install
'python-language-server[all]'~
Alternatively you can use the [[https://pypi.org/project/python-language-server/][Python Language Server]] instead.
~pip install 'python-language-server[all]'~
*To use mspyls*, install it with ~M-x lsp-install-server~ and add this to your
private config.el:
#+BEGIN_SRC elisp
(after! lsp-python-ms
(set-lsp-priority! 'mspyls 1))
#+END_SRC
* Features
This module supports LSP. It requires installation of [[https://pypi.org/project/python-language-server/][Python Language
@@ -114,7 +116,7 @@ To enable support for auto-formatting with black enable ~:editor format-all~ in
| ~<localleader> t O~ | ~nosetests-pdb-one~ |
| ~<localleader> t V~ | ~nosetests-pdb-module~ |
| ~<localleader> t f~ | ~python-pytest-file~ |
| ~<localleader> t k~ | ~python-pytest-file-dwin~ |
| ~<localleader> t k~ | ~python-pytest-file-dwim~ |
| ~<localleader> t t~ | ~python-pytest-function~ |
| ~<localleader> t m~ | ~python-pytest-function-dwim~ |
| ~<localleader> t r~ | ~python-pytest-repeat~ |