Skip to content

Proposal: go/list adds another flag to support showing major upgrade available for module #38502

Closed
@zachgersh

Description

@zachgersh

⚠️ DEPRECATED ⚠️

Please see the linked issue that has replaced this one.

Proposal

Currently, with SIV there isn't an automated way to understand that you may want to upgrade a package to a new major.

For example, if I have a mod that looks like this:

module github.com/test/test

go 1.14

require (
	github.com/peterbourgon/ff v1.7.0 // indirect
	rsc.io/sampler v1.2.1 //indirect
)

and I use go list like so:

go list -m -u all

I am going to get output like this:

github.com/test/test
github.com/BurntSushi/toml v0.3.1
github.com/davecgh/go-spew v1.1.1
github.com/mitchellh/go-wordwrap v1.0.0
github.com/pelletier/go-toml v1.6.0 [v1.7.0]
github.com/peterbourgon/ff v1.7.0
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c [v0.3.2]
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7 [v0.0.0-20191204190536-9bdfabe68543]
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 [v1.0.0-20200227125254-8fa46927fb4f]
gopkg.in/yaml.v2 v2.2.4 [v2.2.8]
rsc.io/sampler v1.2.1 [v1.99.99]

Now github.com/peterbourgon/ff as a module actually has a v2 and a v3 and I would like go list to tell me of their existence sort of like pkg.go.dev does now when I visit the versions page:

Screen Shot 2020-04-17 at 8 34 35 AM

Adding a flag to go list seems like a good step to signal to a user that they may want to upgrade their package to a newer major.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions