Sam Boyer

medium.com/@sdboyer · Personal blog · on HN since 2014

Sam Boyer, a developer who worked on Go dependency management, writes about how package managers are designed and why they are hard.

What HN saysHN commenters repeatedly cite "So you want to write a package manager" as the go-to explanation of the problems, theory and ecosystem issues involved.
30HN people shared it
12linked it in comments
18stories submitted
225story points
10 months agolast shared
2014people per year2026

Most-shared posts

  1. 1
    So you want to write a package manager
    28 people · 224 points · first shared 2016 · 108 comments on HN
  2. 2
    Keeping It Simple
    2 people · 1 points · first shared 2014 · discussion on HN

What HN people wrote when they linked it

thenerdhead · 2023-01-30
Have you read https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae… ? The author does a great job pointing out the problems, theory, and ecosystem change that makes it a Rube Goldberg machine. Source: Also work on a notable package manager.
kellysutton · 2018-02-21
Now is a good time to mention the great blog post, "So you want to write a package manager," by Sam Boyer: https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae…
Groxx · 2016-11-22
Depends on the use. For a library, it doesn't need to be distributed at all, since the application that's using the library will eventually dictate the actual versions of dependencies (so it can play nicely with other libraries). For an application, yes: you commit it along-side the pipfile, and re-generate the lock file when you upgrade things. https://caremad.io/posts/2013/07/setup-vs-requirement/ covers it pretty well. Or https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae… for a fantastic read and a LOT more context.
hobofan · 2022-03-31
> Most package managers have lockfiles > Locking dependencies is, generally, a solved problem across most ecosystems As someone who is building a package manager for work, and has looked at pretty much every package manager out there (and their ecosystem adoption), I can only say that those don't reflect the current reality of package management (no matter how much I wish it were true). Bundler was the first mainstream package manager to adopt a lockfile (AFAIK) a mere 12 years ago. Many many language ecosystems predate that and are still lacking lockfiles (or even widespread adoption of a single compatible package manager). NPM only got lockfiles 5 years ago (after being pressured by yarn). Gradle got them less than 3.5 years ago, and Maven still doesn't have them (though a niche plugin for it exists). The Python ecosystem is still a hot mess, with ~3 competing solutions (Poetry, Pipenv, Conda), of which Conda just got a 1.0 of their decent conda-lock incubation project a month ago, but due to how setuputils works, the cross-platform package management story is broken almost beyond recovery. In Conan lockfiles are still an experimental feature today. I could go on and on, but I hope that I could paint a picture that while one could argue that with the advent of lockfiles, locking dependencies has become a solved problem _conceptually_, the current status of implementation across ecosystems is still horrible. I'm also constantly amazed about how little love is put into…
jasode · 2019-04-21
>, but what is there to be opinionated about with a build system? I think you're saying this because your idea of a "build system" is a very simple set of sequential steps from known source code input files to an output binary. The differing opinions come in when the "build system" includes various contradictory philosophies of how to configure and specify the building of complex software. Different opinions on: - syntax : should build config be XML, or JSON, or YAML, or custom syntax? E.g. Ant and Maven used XML but Gradle does not - dependencies search: should build system implicitly find and add relevant dependencies? Or should programmer explicitly specify each one? - reproducible builds (version pinning) vs auto-updated dependencies. - should the build system be "smart" about cross-platform differences? If yes, you end up with complicated build tools like GNU Autoconf "configure" bash script, or CMake's complex syntax. - should build system do optimization and bundling tasks that's not strictly limited to "compile" steps? Some Javascript build tools try to eliminate redundant or unused js code to make downloads smaller. - etc, etc. I also recommend reading the blog post "So you want to write a package manager"[1] to get an idea of how complicated a build system can get. The title says "package manager" but much of the material is also about build systems. The bottom line is that reasonable people can disagree on the priorities and therefore, you can't…
steveklabnik · 2017-12-21
> I'm interested in your view about this very aspect. I'm conflicted. I personally waver between "stallman is always right" and "free software misses the point" near constantly, myself. With regards to WebAssembly, it's also complicated. You can argue that JavaScript is basically in the same place, and so for me, it's kind of a moot point. That is, there's no requirement for JavaScript to be free software today either. In practice, obfuscated/minified JS and WebAssembly are basically the same, with the exception that the tooling for de-{obfuscating,compiling} JS is currently more robust and mature since it's been around a lot longer. TL;DR: I don't think that WebAssembly really changes the game here, for good or for bad. > I didn't mean to restrict this to Apt Quite fair! And as I alluded to above, it's not just the thing that I posted. This is quite long but I have little time, so I'm gonna be brief. https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae… basically is, IMO, the gold standard for talking about these things. However, I think the distinction of OS/system package manager vs Language package manager is important. Basically, Cargo and Apt (I'll follow your lead here with using Apt as a standin) have very different goals, and very different constants. This is because they're doing two very different jobs. Specifically, system package managers are about providing a unified set of packages to end-users. Language package managers are for…
cben · 2026-01-05
Obligatory link to the gold intro to So. Many. Aspects. of pkg manager design: https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae… Even if its section on "Central Package Registry" isn't very deep.
mkobit · 2018-10-02
I think of this article (https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae… when it comes to package management.
zalmoxes · 2016-07-29
Sam Boyer, one of the other people in the document wrote a nice article that dives into the complexity of dependency management. https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae… Discussion https://news.ycombinator.com/item?id=11088125 Sam is currently working on a library for Go https://github.com/sdboyer/gps
chewxy · 2016-03-23
Semi related but recently Sam Boyer wrote a good article about writing a package manager. He explores the topic quite well, indicating that there are several things that are conflated as package managers https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae…
pessimizer · 2014-11-01
Drupal, in particular, is harder than it has to be. I really liked this article from Sam Boyer: https://medium.com/@sdboyer/keeping-it-simple-944526c5b7fb

Keyboard shortcuts

/Search
j kNext / previous blog
EnterOpen selected blog
vVisit the blog site
fFollow / unfollow
lSwitch grid / list view
dSwitch dark mode
g hHome
g pTop posts
g tTopics
g fFollowing
g lLiked
g yHistory
g qFAQ
EscBack / close