1
0
mirror of https://github.com/golang/go synced 2024-11-18 13:24:39 -07:00
go/cmd/golsp/integration/vscode
Rebecca Stambler feaab9440b cmd/golsp/integration/vscode: add language server client for testing
We've been using https://github.com/stamblerre/vscode-test-golsp to test
the golsp. Ideally, we'd like to add integration tests with the major
editors, so we're moving this basic extension into x/tools, with the
intention of integration tests here. This is not meant to be used by any
users of golsp; it is only for testing.

Change-Id: I7c45e7c638311d29629ff6d3291332e68cf4621a
Reviewed-on: https://go-review.googlesource.com/c/153438
Reviewed-by: Ian Cottrell <iancottrell@google.com>
2018-12-10 22:45:52 +00:00
..
.vscode cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00
src cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00
package-lock.json cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00
package.json cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00
README.md cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00
tsconfig.json cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00
tslint.json cmd/golsp/integration/vscode: add language server client for testing 2018-12-10 22:45:52 +00:00

golsp testing extension

An extension for debugging the Go Language Server provided by https://golang.org/x/tools/cmd/golsp. The code for this extension comes from a combination of https://github.com/Microsoft/vscode-extension-samples/blob/master/lsp-sample and https://github.com/Microsoft/vscode-go.

Features

  • Diagnostics (on file change)
  • Completion (Ctrl + Space)
  • Jump to definition (F12 or right-click -> Go to Definition)
  • Signature help (Ctrl + Shift + Space)

Installation

To package the extension, run vsce package from this directory. To install the extension, navigate to the "Extensions" panel in VSCode, and select "Install from VSIX..." from the menu in the top right corner. Choose the golsp-1.0.0.vsix file and reload VSCode.