To fully implement this module support a new major release needs to be done (v3)
Therefore, I've changed import paths in this package to reflect this: log "github.com/inconshreveable/log15/v3"
Readme is updated accordingly.
Personal experience: Go expects a 3-numbered version, or modules will not work. So next release should be tagged like v3.0.0
It is recommended (but not required) to keep a separate v3 branch from which v3 releases are done. This has to do with long term support of individual module versions.
Go version support
Modules is supported by Go versions 1.9.7+, 1.10.3+, or 1.11+. 1.9 is the lowest version in .travis.yml. Hence, go.mod has go 1.9 as minimal supported version for this package.
Tested
I've done a test release on my own fork of this repository to verify things are done right. I've tested go get and module versioning in a dependent package.
Note: package name in my test release reflects my own repository path, while this PR reflects github.com/inconshreveable/log15
In go.mod:
require github.com/usrpro/log15/v3 v3.1.0
Import:
import log "github.com/usrpro/log15/v3"
Ran:
$ go get -u -v ./...
go: downloading github.com/usrpro/log15/v3 v3.1.0
github.com/usrpro/log15/v3
This PR adds a go.mod file and closes #152
As per recommendations from the Go Modules wiki page:
log "github.com/inconshreveable/log15/v3"
v3.0.0
v3
branch from whichv3
releases are done. This has to do with long term support of individual module versions.Go version support
Modules is supported by Go versions
1.9.7+
,1.10.3+
, or1.11+
.1.9
is the lowest version in.travis.yml
. Hence,go.mod
hasgo 1.9
as minimal supported version for this package.Tested
I've done a test release on my own fork of this repository to verify things are done right. I've tested
go get
and module versioning in a dependent package.Note: package name in my test release reflects my own repository path, while this PR reflects
github.com/inconshreveable/log15
In
go.mod
:Import:
Ran:
All worked OK :ballot_box_with_check: