Please Use Go Mods

May 17, 2020

A pretty short post.

No longer will you have to deal with dependency issues because your project is not set in the gopath. Now you can just run the following to make life much easier:

go mod init

Or you can be more specific using:

go mod init<username>/<project/repo-name>

This will set up your project to easily use third-party modules. If you need a specific module just:

go get -u <module-name>

The above will also update your dependency if you needed that.

As promised, done!