I'll start off by saying I've never written a line of Go code. I started reading some Go code and trying to figure out how dependencies work and it's a completely baffling to me even after skimming the docs. I'm guessing the answer here for some of this stuff is just that Go is a newer language and hasn't figured all of this out, but I'm really curious how people use Go to build larger projects right now.Things I'm confused about:
- You depend on source code instead of binaries?
- You always depend on head and there's no way to depend on a version of a library?
- How does a library get updated? Does the build process essentially do a git pull on every transitive library dependency each time you compile? Or once you download the code it doesn't update? The former seems not very performant. The latter seems like a nightmare in working with a team where everyone ends up with a different dependency versions depending on when they downloaded the code.
- This seems awfully brittle. What happens when someone deletes a GitHub repo you depended on? Coming from Java this is not a worry because once you publish a package to the Maven central repository it is always there. Also, if someone changes where they host their source code you have to update it in every single file that uses that package? That seems rather strange to me as well compared to having a list of packages configured one place in your project (like a build file) and imports that do not rely on the source code location. This has happened several times with dependencies I've used in Java and there it requires absolutely no changes, but seems really hard in Go. E.g. someone moves their project from Sourceforge to GitHub or from their personal GitHub to a GitHub organization. In Go that seems like a complete nightmare because you have to not only update every file in your project to point to the new location, but you also have to get all the libraries you depend on transitively that may depend on the same library to also make the same change.
Appreciate the help. It looks like this group is trying to come up with better solutions for some of these problems, so I'm guessing these are all things you've thought about.
Thanks,Ben--
You received this message because you are subscribed to the Google Groups "Go Package Management" group.
To unsubscribe from this group and stop receiving emails from it, send an email to go-package-manag...@googlegroups.com.
To post to this group, send email to go-package...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
- You depend on source code instead of binaries?
- You always depend on head and there's no way to depend on a version of a library?
- How does a library get updated?
- This seems awfully brittle.
--
You received this message because you are subscribed to a topic in the Google Groups "Go Package Management" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/go-package-management/bTWi4KanW8M/unsubscribe.
To unsubscribe from this group and all its topics, send an email to go-package-manag...@googlegroups.com.
To post to this group, send email to go-package...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Thanks for the replies. This is becoming much clearer to me now. One follow up... I'm not familiar with the term "vendoring". Could you describe what this means or point me at a resource for it?
At the risk of side tracking the conversation, I think the concept of vendoring predates Ruby On Rails. According to Wikipedia[1] Ruby On Rails as an open source project dates back to July 2004.
I have found descriptions of the concept of vendoring, however, as old as 1998 in "Streamed Lines: Branching Patterns for Parallel Software Development"[2]. Although this source calls the pattern "Third Party Codeline" the word "vendor" appears 18 times in the description and the illustrative diagram uses "vendor" as the name of the branch.
In addition, the Subversion Book for Subversion v1.0 (2002) has a section describing the practice of maintaining vendor branches.[3]
These last two references also provide a very detailed explanation of the reasons for vendoring that should easily suffice to answer the question, "What is vendoring?". So hopefully I have added value beyond the etymological debate.
[1] http://en.wikipedia.org/wiki/Ruby_on_Rails#History
[2] http://www.bradapp.com/acme/branching/branch-structs.html#ThirdPartyLine
[3] http://svnbook.red-bean.com/en/1.0/svn-book.html#svn-ch-7-sect-4
The term comes from the Ruby On Rails vendor directory.
Thank you for the historical references. I did not know that the vendor directory name predated Rails. As far as I now, the use of "vendor" as a verb emerged in the Ruby community.
--
You received this message because you are subscribed to the Google Groups "Go Package Management" group.
To unsubscribe from this group and stop receiving emails from it, send an email to go-package-manag...@googlegroups.com.