Tuesday, March 24, 2020

golang: go get - download project and it's dep.

Get downloads the packages named by the import paths, along with their dependencies. It then installs the named packages, like 'go install'.

$ go get -d -u github.com/user/projectname (DO NOT USE http:// or https://)

The -d flag instructs get to stop after downloading the packages; that is, it instructs get not to install the packages.

The -u flag instructs get to use the network to update the named packages and their dependencies. By default, get uses the network to check out missing packages but does not use it to look for updates to existing packages.

The -v flag enables verbose progress and debug output.

No comments:

Post a Comment