oschwald / maxminddb-golang

MaxMind DB Reader for Go
ISC License
576 stars 99 forks source link

add gomodules support #49

Closed mroth closed 4 years ago

mroth commented 5 years ago

Go Modules 📦 have been supported since Go 1.11 as the officially blessed "preliminary support" for dependency management and reproducible builds, and while the writing was on the wall for a while, it seems it's now official that this seems to be the path forward in the Go ecosystem.

This PR adds a standard go module definition for this repository (generated via go mod init and go mod tidy), indicating the current state of the dependency chain. This should simplify things for other people importing this library in their projects (like me!), as well as some other niceness like allowing working outside of GOPATH if desired.

(Note: I'm not 100% certain, but I believe due to semantic versioning requirements any other programs which depend on this will not be able to actually take advantage until there is a tagged git release that includes it, even after it is merged.)