commit | f01a4bec33ece3df6ee6b1d58d0e7eec857342ac | [log] [tgz] |
---|---|---|
author | Rebecca Stambler <rstambler@golang.org> | Fri Jun 26 01:34:55 2020 -0400 |
committer | Rebecca Stambler <rstambler@golang.org> | Wed Jul 01 22:10:12 2020 +0000 |
tree | 916cb6ddb402bbee9e1bbb71afb773e2197dfdc3 | |
parent | ea7be8d74e7b0eda372530db3d50b4655d52a138 [diff] |
internal/lsp: support opening single files This change permits starting gopls without a root URI or any workspace folders. If no view is found for an opened file, we try to create a new view based on the module root of that file. In GOPATH mode, we just use the directory containing the file. I wrote a regtest for this by adding a new configuration that gets propagated to the sandbox. I'm not sure if this is the best way to do that, so I'll let Rob advise. Fixes golang/go#34160 Change-Id: I3deca3ac1b86b69eba416891a1c28fd35658a2ed Reviewed-on: https://go-review.googlesource.com/c/tools/+/240099 Run-TryBot: Rebecca Stambler <rstambler@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Heschi Kreinick <heschi@google.com>
This subrepository holds the source for various packages and tools that support the Go programming language.
Some of the tools, godoc
and vet
for example, are included in binary Go distributions.
Others, including the Go guru
and the test coverage tool, can be fetched with go get
.
Packages include a type-checker for Go and an implementation of the Static Single Assignment form (SSA) representation for Go programs.
The easiest way to install is to run go get -u golang.org/x/tools/...
. You can also manually git clone the repository to $GOPATH/src/golang.org/x/tools
.
This repository uses prettier to format JS and CSS files.
The version of prettier
used is 1.18.2.
It is encouraged that all JS and CSS code be run through this before submitting a change. However, it is not a strict requirement enforced by CI.
This repository uses Gerrit for code changes. To learn how to submit changes to this repository, see https://golang.org/doc/contribute.html.
The main issue tracker for the tools repository is located at https://github.com/golang/go/issues. Prefix your issue with “x/tools/(your subdir):” in the subject line, so it is easy to find.