psampaz/go-mod-outdated

list outdated modules with same Minor version (so see patch update only)

jerome-laforge opened this issue · 1 comments

Hello

Currently, I am not able to list new version of module but for patch only.

For example:

module github.com/test/test

go 1.15

require go.mongodb.org/mongo-driver v1.3.6

I want to know if a new patch version if available (here v1.3.7 and not v1.4.0), but I don't know how to do.
The given example here https://github.com/golang/go/wiki/Modules#how-to-upgrade-and-downgrade-dependencies is for direct with minor and patch (I just want patch). And yet, the v1.3.7 has been released (https://pkg.go.dev/mod/go.mongodb.org/mongo-driver@v1.3.7).

$ go list -u -m all | grep "go.mongodb.org/mongo-driver"
go.mongodb.org/mongo-driver v1.3.6 [v1.4.0]

I want use this in my CI with psampaz/go-mod-outdated from @psampaz but only for patch version with something like (with option -patch & use go list -versions) :

go list -versions -u -m -json all | go-mod-outdated -update -direct -style markdown -ci -patch

related to golang/go#40990

I take a look into the FilterModules func. That seems more consistent if go list accept -u=patch.

So I have just created this proposal golang/go#41006 and I close this issue.

Sorry for the noise.