-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This change establishes that "go generate ./..." from within the gopls directory will update all generated code in the module to its canonical version. (Beware that this command doesn't work in the parent directory due to golang/go#58723.) Details: - The main 'generate' command now includes the canonical git ref name of the LSP protocol used by gopls, and by default it clones the repo at this version instead of using the version in pjw's home directory. ;-) It should deliver identical results for all users without setup. The "generated" comment includes an accurate URL. The timestamp is removed since it is nondeterministic. - In addition to the commit hash, the output now reports the git ref (branch/tag) name, which is not the same as the metadata.version (LSP protocol version) string. - The go:generate comments are now more prominent in their respective files. We hide several that appear in testdata from the go command by splitting string literals. - Improved command documentation for generators. - Use a slice not map for genTypes so that protocol generation is deterministic. (Previously the "created for" comments would alternate between TextDocumentFilter_Item{0,1}.) The generated output has changed trivially ("//x" -> "// x") because the most recent committed generated files was stale wrt recent generator changes. Also, line number comments now start at 1, not zero (eliminating a TODO). Change-Id: I40e9454d0042507bd64e0d8fab3ce6b1fbe87ddc Reviewed-on: https://go-review.googlesource.com/c/tools/+/471115 Run-TryBot: Alan Donovan <adonovan@google.com> gopls-CI: kokoro <noreply+kokoro@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Robert Findley <rfindley@google.com> Reviewed-by: Peter Weinberger <pjw@google.com>
- Loading branch information
Showing
18 changed files
with
2,171 additions
and
2,126 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.