andrey_derma
andrey_derma

Reputation: 53

go get specific version

I want to know how go get works, because when im using a libary from github (for example gorilla/mux) the documentation said to install it I should type "go get -u github.com/gorilla/mux", it strange without specific version.!

As far as i know it always use from master branch. What happen if the owner of the library update the code? Is it gonna be deprecated or something?

Because in my case, im using docker to build the project, every time I build the image, it always do "go get"

Is there any best practice to using go get?

Upvotes: 0

Views: 2293

Answers (1)

Artur
Artur

Reputation: 149

You may use go get library@version. For example, go get foo/[email protected]

Upvotes: 1

Related Questions