Last active
April 25, 2019 13:11
-
-
Save sai-prasanna/45a9d7e960fd0865b8466c1b8caba7e2 to your computer and use it in GitHub Desktop.
Make lsp autocomplete work in emacs over TRAMP
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
;; Put this in root directory of your project | |
;; Install pyls in the project environment | |
;; pip install python-language-server | |
((python-mode . ((eval . (progn (require 'lsp-mode) | |
(lsp-register-client | |
(make-lsp-client :new-connection (lsp-tramp-connection "~/miniconda3/envs/znlp/bin/pyls") | |
:major-modes '(python-mode) | |
:remote? t | |
:server-id 'remote-pyls)))) | |
(eval . (setq lsp-clients-python-command '("~/miniconda3/envs/znlp/bin/pyls"))) | |
))) |
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
( | |
dotspacemacs-configuration-layers | |
'(lsp | |
(python :variables python-backend 'lsp) | |
;; other layers ... | |
) | |
) | |
(defun dotspacemacs/user-config () | |
;; Other stuff.. | |
;; TRAMP | |
(setq enable-remote-dir-locals t) | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment