Compare commits
2 commits
119c44a8e7
...
4abd34b8b4
Author | SHA1 | Date | |
---|---|---|---|
4abd34b8b4 | |||
86588ecab6 |
2 changed files with 22 additions and 2 deletions
19
config.org
19
config.org
|
@ -641,3 +641,22 @@
|
|||
|
||||
(add-to-list 'window-buffer-change-functions 'my/track-python-virtualenv)
|
||||
#+end_src
|
||||
|
||||
同时启用 pylint 和 pyright-lsp 。
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(defvar-local my/flycheck-local-cache nil)
|
||||
|
||||
(defun my/flycheck-checker-get (fn checker property)
|
||||
(or (alist-get property (alist-get checker my/flycheck-local-cache))
|
||||
(funcall fn checker property)))
|
||||
|
||||
(advice-add 'flycheck-checker-get :around 'my/flycheck-checker-get)
|
||||
|
||||
(add-hook 'lsp-managed-mode-hook
|
||||
(lambda ()
|
||||
(when (and (string= nil (file-remote-p default-directory))
|
||||
(derived-mode-p 'python-mode))
|
||||
(setq my/flycheck-local-cache '((lsp . ((next-checkers . (python-pylint)))))))))
|
||||
|
||||
#+end_src
|
||||
|
|
5
init.el
5
init.el
|
@ -20,8 +20,9 @@
|
|||
;;layout ; auie,ctsrnm is the superior home row
|
||||
|
||||
:completion
|
||||
(company
|
||||
+childframe) ; the ultimate code completion backend
|
||||
(corfu +orderless) ; complete with cap(f), cape and a flying feather!
|
||||
;; (company
|
||||
;; +childframe) ; the ultimate code completion backend
|
||||
;;helm ; the *other* search engine for love and life
|
||||
;;ido ; the other *other* search engine...
|
||||
;;ivy ; a search engine for love and life
|
||||
|
|
Loading…
Reference in a new issue