File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -428,6 +428,16 @@ These are assembled from the customizable variables `lsp-go-server-path'
428
428
and `lsp-go-server-wrapper-function' ."
429
429
(funcall lsp-go-server-wrapper-function (append (list lsp-go-gopls-server-path) lsp-go-gopls-server-args)))
430
430
431
+ (defun lsp-go--cls-download-server (_client callback error-callback _update? )
432
+ " Install/update shader-ls language server using `go install'.
433
+
434
+ Will invoke CALLBACK or ERROR-CALLBACK based on result.
435
+ Will update if UPDATE? is t"
436
+ (lsp-async-start-process
437
+ callback
438
+ error-callback
439
+ " go" " install" " golang.org/x/tools/gopls@latest" ))
440
+
431
441
(lsp-register-client
432
442
(make-lsp-client :new-connection (lsp-stdio-connection 'lsp-go--server-command )
433
443
:activation-fn (lsp-activate-on " go" " go.mod" )
@@ -438,7 +448,8 @@ and `lsp-go-server-wrapper-function'."
438
448
:library-folders-fn #'lsp-go--library-default-directories
439
449
:after-open-fn (lambda ()
440
450
; ; https://github.com/golang/tools/commit/b2d8b0336
441
- (setq-local lsp-completion-filter-on-incomplete nil ))))
451
+ (setq-local lsp-completion-filter-on-incomplete nil ))
452
+ :download-server-fn #'lsp-go--cls-download-server ))
442
453
443
454
(lsp-consistency-check lsp-go)
444
455
You can’t perform that action at this time.
0 commit comments