LSP shouldn't be turned on by default

At least, not until i can tame this beast.
This commit is contained in:
Howard Abrams 2022-05-10 11:25:10 -07:00
parent 0b64f4ab26
commit 6aa3efdf54

View file

@ -162,16 +162,12 @@ The [[https://github.com/emacs-lsp/lsp-pyright][pyright package]] works with LSP
(setq lsp-pyright-python-executable-cmd "python3"))) (setq lsp-pyright-python-executable-cmd "python3")))
#+END_SRC #+END_SRC
* LSP Integration of Python * LSP Integration of Python
Now that the [[file:ha-programming.org::*Language Server Protocol (LSP) Integration][LSP Integration]] is complete, we can stitch the two projects together: Now that the [[file:ha-programming.org::*Language Server Protocol (LSP) Integration][LSP Integration]] is complete, we can stitch the two projects together, by calling =lsp=. I oscillate between automatically turning on LSP mode with every Python file, but I sometimes run into issues when starting, so I turn it on with ~SPC m w s~.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(use-package lsp-mode (use-package lsp-mode
:hook ((python-mode . lsp))) ;; :hook ((python-mode . lsp)))
#+END_SRC :config
And we're done. Except that I would like a select collection of LSP keybindings for Python.
#+BEGIN_SRC emacs-lisp
(ha-python-leader (ha-python-leader
"0" '("treemacs" . lsp-treemacs-symbols) "0" '("treemacs" . lsp-treemacs-symbols)
@ -261,7 +257,7 @@ And we're done. Except that I would like a select collection of LSP keybindings
"wd" '("describe session" . lsp-describe-session) "wd" '("describe session" . lsp-describe-session)
"wq" '("shutdown server" . lsp-workspace-shutdown) "wq" '("shutdown server" . lsp-workspace-shutdown)
"wr" '("restart server" . lsp-workspace-restart) "wr" '("restart server" . lsp-workspace-restart)
"ws" '("start server" . lsp)) "ws" '("start server" . lsp)))
#+END_SRC #+END_SRC
* Project Configuration * Project Configuration
I work with a lot of projects with my team where I need to /configure/ the project such that LSP and my Emacs setup works. Let's suppose I could point a function at a project directory, and have it /set it up/: I work with a lot of projects with my team where I need to /configure/ the project such that LSP and my Emacs setup works. Let's suppose I could point a function at a project directory, and have it /set it up/: