Distributing your own scripts via Homebrew

justin.searls.co

77 points by ingve 6 days ago


frou_dh - 4 hours ago

There was actually an episode of the Ruby Rogues podcast released only a few days after this post that touched on much of the same stuff:

https://topenddevs.com/podcasts/ruby-rogues/episodes/distrib...

darkamaul - 3 days ago

Really informative read, I agree that Homebrew’s naming conventions can be frustrating at times, but overall it’s such a great tool.

I hadn’t realized it was this simple to spin up your own tap for distributing tools. How does this compare to using language specific tools (like uv, for example)? Is it better because that’s easier for folks not within the ecosystem ?

jbreckmckye - 3 days ago

A small tip for Go folk: the Goreleaser tool makes it very easy to manage your formulae, at least for distributing binaries (allowed in personal taps but a no-no in core)

wyattjoh - 3 days ago

I wrote my own version of the homebrew tap bumping workflow for GitHub Actions: https://github.com/wyattjoh/homebrew-bump-revision I use it for some of my personal projects

loozhengyuan - 3 days ago

IMO it might be more ideal to do the updates from the tap side, similar to how upstream does it. This workflow[1] allows you handle updates even for formulae/casks you do not own. Using the `brew bump` command, you scan all formulae/casks and create PRs that update them. In these PRs[2], you can use the `brew test-bot` command to ensure the updates are tested working.

[1]: https://github.com/loozhengyuan/homebrew-tap/blob/main/.gith...

[2]: https://github.com/loozhengyuan/homebrew-tap/pull/11

PufPufPuf - 3 days ago

Fun fact about packaging Python tools: It turns out that there are Python packages that aren't compatible with Homebrew due to cycles in build dependencies. While this is no problem for pip, as it just downloads binary releases, Homebrew builds ALL of the dependencies from scratch. And yeah, that also means that modestly sized Python projects may take over an hour to build the "bottle".

xyst - 3 days ago

I switched to nix to manage my systems and haven’t looked back. The only thing lacking is a single dependency on shitty windows for multiplayer gaming.