Fix company/lookup settings in anaconda-mode

Applying them to python-mode means it would happen too late.
This commit is contained in:
Henrik Lissner 2018-07-31 19:20:58 +02:00
parent 26cc2a4f8a
commit d9a52e1094
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -70,12 +70,12 @@ first to return non-nil will have its result appended to the python-mode
anaconda-mode-eldoc-as-single-line t) anaconda-mode-eldoc-as-single-line t)
:config :config
(add-hook 'anaconda-mode-hook #'anaconda-eldoc-mode) (add-hook 'anaconda-mode-hook #'anaconda-eldoc-mode)
(set-company-backend! 'python-mode '(company-anaconda)) (set-company-backend! 'anaconda-mode '(company-anaconda))
(set-popup-rule! "^\\*anaconda-mode" :select nil) (set-lookup-handlers! 'anaconda-mode
(set-lookup-handlers! 'python-mode
:definition #'anaconda-mode-find-definitions :definition #'anaconda-mode-find-definitions
:references #'anaconda-mode-find-references :references #'anaconda-mode-find-references
:documentation #'anaconda-mode-show-doc) :documentation #'anaconda-mode-show-doc)
(set-popup-rule! "^\\*anaconda-mode" :select nil)
(defun +python|auto-kill-anaconda-processes () (defun +python|auto-kill-anaconda-processes ()
"Kill anaconda processes if this buffer is the last python buffer." "Kill anaconda processes if this buffer is the last python buffer."