From 6780d7c81665b35a2a02be80ab4b14df724625c0 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sat, 9 May 2020 01:13:04 -0400 Subject: [PATCH] Update python readme wrt mspyls & pyls Since lsp-python-ms changed its priority from 1 to -1 in emacs-lsp/lsp-python-ms@396c25c, it is no longer the first choice when both is available. --- modules/lang/python/README.org | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/modules/lang/python/README.org b/modules/lang/python/README.org index ebb303ac2..3660636eb 100644 --- a/modules/lang/python/README.org +++ b/modules/lang/python/README.org @@ -79,14 +79,19 @@ This module has no direct prerequisites. Here are some of its soft dependencies. ** Language Server Protocol Support This module must be enabled with the =+lsp= flag, and the =:tools lsp= module -must be enabled. LSP will try mspyls, then pyls; whichever is available. +must be enabled. LSP will try pyls then mspyls; the first that is available. -mypyls can be installed with ~M-x lsp-install-server~ after opening a python -buffer. - -Alternatively, use the [[https://pypi.org/project/python-language-server/][Python Language Server]] instead. ~pip install +*To use [[https://pypi.org/project/python-language-server/][Python Language Server]] (pyls)* install it with ~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 Server]] or [[https://github.com/Microsoft/python-language-server][Microsoft Language Server]], see [[Language Server Protocol Support][LSP Support]].