diff options
author | Franck Cuny <franck.cuny@gmail.com> | 2020-01-13 09:29:34 -0800 |
---|---|---|
committer | Franck Cuny <franck.cuny@gmail.com> | 2020-01-13 09:29:34 -0800 |
commit | e3270cc826cc1d0a64c93b3d317263949ea06902 (patch) | |
tree | 734d8bc8027b8db26b74013b0da9577a2dbe191d /emacs.d/custom/fcuny-go.el | |
parent | emacs/ui: font size (diff) | |
download | emacs.d-e3270cc826cc1d0a64c93b3d317263949ea06902.tar.gz |
emacs/prog: switch to lsp-mode
Previously I was using the package `eglot` to provide LSP functionality. However, the package uses flymake for it, while my setup in general uses flycheck. Since lsp-mode supports both, I'm switching to ls-mode. I'm moving the code for company to the 'prog' module, so that all things related to general programming is in one location. Since I'm switching to lsp-mode mode primarily for go, I can also delete a bunch of extra functionality that is now provided by lsp-mode.
Diffstat (limited to '')
-rw-r--r-- | emacs.d/custom/fcuny-go.el | 54 |
1 files changed, 1 insertions, 53 deletions
diff --git a/emacs.d/custom/fcuny-go.el b/emacs.d/custom/fcuny-go.el index ffbc1d5..4484b6e 100644 --- a/emacs.d/custom/fcuny-go.el +++ b/emacs.d/custom/fcuny-go.el @@ -20,62 +20,10 @@ :config (when (memq window-system '(mac ns)) - (exec-path-from-shell-copy-env "GOPATH")) - - (defhydra hydra-go-menu (:hint nil) - " -^find ^ ^goto ^ ^test^ -^-----------^ ^--------^ ^----^ -_r_: referrers _d_: definition _T_: test current test -_i_: implements _a_: arguments _F_: test current file -_D_: describe _f_: function _P_: test current package -^ ^ _R_: return -" - ("r" go-guru-referrers) - ("i" go-guru-implements) - ("D" go-guru-describe) - ("d" go-guru-definition) - ("a" go-goto-arguments) - ("f" go-goto-function) - ("R" go-goto-return-values) - ("T" go-test-current-test) - ("F" go-test-current-file) - ("P" go-test-current-project) - ("q" nil "quit" :color blue)) - - (define-key go-mode-map (kbd "C-c g") 'hydra-go-menu/body)) - -(use-package go-guru - :ensure t - :after go-mode - :commands (go-guru-describe go-guru-freevars go-guru-implements go-guru-peers - go-guru-referrers go-guru-definition go-guru-pointsto - go-guru-callstack go-guru-whicherrs go-guru-callers go-guru-callees - go-guru-expand-region) - :config - (unless (executable-find "guru") - (warn "go-mode: couldn't find guru, refactoring commands won't work")) - (add-hook 'go-mode-hook #'go-guru-hl-identifier-mode)) - -(use-package go-eldoc - :ensure t - :after go-mode - :config - (add-hook 'go-mode-hook 'go-eldoc-setup)) - -(use-package godoctor - :ensure t - :after go-mode) + (exec-path-from-shell-copy-env "GOPATH"))) (use-package gotest :ensure t :after go-mode) -(use-package company-go - :ensure t - :after (company) - :hook (go-mode . (lambda () - (setq-local company-backends - (append (list 'company-go) company-backends))))) - (provide 'fcuny-go) |