On Monday, January 7, 2013 5:50:35 PM UTC+1, André Moraes wrote:
Just a reminder, but go generate static linked binary, with the
exception of cgo linked libraries, those are shared-libraries.
So far, I'm relying on the lightning fast compilation, and not sharing binaries. This is too tricky to handle both project version, and golang version (binaries from 1.0.2 won't compile with binaries from 1.0.3).
A local repository contains the binaries that are not compiled unless -a option is called (to avoid usuless recompiling)
Also, avoid breaking the "go get" behavior. It will make things
complex at the best case scenario.
Agreed, I'll do my best to keep it, even if it's difficult. But in case I can't what are the main "benefits" ?
Is it the way to easily link to another project ? "go get github/foo/bar" and that's it
The problems with "go get" today:
* you can't "get" a specific version (keep the "master" green)
especially with CI, and in team environement
* you can't do custom build steps
like generating sources with protobuf (unless you "commit" generated sources !! (OMG this is forbidden by the holly rules of cthulhu !!)
* you can't install to a location different from the location that you
downloaded
like forking a repository to fix some stuff, and use it i your project instead of the original code.
All those three points are solvable using Makefile and the last
command called is "go build/install"
or gopack ;-)
People using Go expect to have "go get/build/install/doc" working on
every single package after the first install of the given package.
Avoid breaking that expectation.
Could you detail the expectation for go build ? isn't go install enough ?
I would add "go test" to the list.
Nevertheless, with gopack, the dependency manager can print out a GOPATH compatible string so you can set your gopath variable with it, and use the full go tool chain as usual.