4 ms·
I think the bit on managing dependencies could be improved with a bit more information about what other people have done. For example, SoundCloud maintains one
by jzelinskie 12y ago
I think the bit on managing dependencies could be improved with a bit more information about what other people have done. For example, SoundCloud maintains one monolithic $GOPATH in a single git repository that they can then selectively update. My personal preference to any flavor of the month Go dependency managers is gopkg.in[0], because it doesn't fool with the official tool chain (i.e. "go get", "go build"), but still allows for the versioning of packages.
[0] http://labix.org/gopkg.in http://labix.org/gopkg.in
- sagichmal 12y ago> For example, SoundCloud maintains one monolithic $GOPATH > in a single git repository that they can then > selectively update. No, we tell developers to use a single $GOPATH on their machine, and check out/edit code directly in the canonical location, e.g. $GOPATH/src/github.com/soundcloud/foosvc
- emeraldd 12y agoHow do you handle a single developer working on multiple features/branches/issues at the same time?
- NateDad 12y agoThis is what source control is for. You switch to the branch and hack on it. In the rare case you need different versions of dependencies, you use a tool like godep (but if you have to resort to that, you're doing something wrong, your dependencies should have stable APIs). Don't use multiple spots on your hard drive for code in source control. Use source control for what it's made for.
- sagichmal 12y agoWhat NateDad said: > This is what source control is for. You switch to the > branch and hack on it. We're also running a microservice (SOA) architecture; each repo represents one service, with one (hopefully) tightly-constrained purpose. It's very rare that we're doing more than 1 or 2 feature branches in a repo at one time.
- aaronblohowiak 12y agoOur GOPATH per project is `pwd`:`pwd`/vendor and in vendor we use a git subtree to a shared repo where we have forked our external dependencies. It isn't great because merging in updates from upstream is annoying, but it is simple and isn't something we have to think about 99% of the time.
- jzelinskie 12y agoThank you for this clarification. I'm fairly certain I was under that impression due to a misinterpreted description of this system. This does support my point, though, that more people need to discuss this topic. Instead of "generics", "versioning" needs to be the most popular complaint with the language, because it's something that can be standardized in the community.
- aaronblohowiak 12y agoNot sure if it is ambiguous, but in my post 'our' is Fan.tv, not Soundcloud!