]> Cypherpunks repositories - gostls13.git/commit
cmd/go/internal/modload: make 'list -u' consider current pseudoversion
authorPontus Leitzler <leitzler@gmail.com>
Mon, 29 Apr 2019 09:50:53 +0000 (09:50 +0000)
committerJay Conrod <jayconrod@google.com>
Thu, 2 May 2019 14:47:22 +0000 (14:47 +0000)
commitf03b3331c74ae45f0a5053287a26dd522f89f462
tree4471f3d495ade0873771589c3b9acd88b43f2892
parente4c0e9df8b328395570948f1b3fa4dc3235432f0
cmd/go/internal/modload: make 'list -u' consider current pseudoversion

As pointed out by thepudds in #30634, the 'list -u' documentation states that the current version should be considered for upgrade:
The -u flag adds information about available upgrades. When the latest version of a given module is newer than the current one, list -u sets the Module's Update field to information about the newer module.

In go 1.12.4 (and current tip), an older version will be suggested as upgrade to a newer pseudo version.

Updates: #30634

Change-Id: If2c8887198884b8e7ccb3a604908065aa1f1878a
Reviewed-on: https://go-review.googlesource.com/c/go/+/174206
Run-TryBot: Jay Conrod <jayconrod@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Jay Conrod <jayconrod@google.com>
src/cmd/go/internal/modload/build.go
src/cmd/go/testdata/mod/example.com_pseudoupgrade_v0.0.0-20190429073000-30950c05d534.txt [new file with mode: 0644]
src/cmd/go/testdata/mod/example.com_pseudoupgrade_v0.1.0.txt [new file with mode: 0644]
src/cmd/go/testdata/mod/example.com_pseudoupgrade_v0.1.1-0.20190429073117-b5426c86b553.txt [new file with mode: 0644]
src/cmd/go/testdata/script/mod_get_upgrade_pseudo.txt [new file with mode: 0644]
src/cmd/go/testdata/script/mod_list_upgrade_pseudo.txt [new file with mode: 0644]