Live data from Hacker News

Sapphire: Rust based package manager for macOS

github.com

281–290 of 311 posts

Re: Sapphire: Rust based package manager for macOS

#282
post #271

Earlier quoted context omitted.

Doesn’t tell me how it differs Not everything on HN has to come with a dissection and explanatory note - that's kind of the point of curiosity. If it’s just a for fun personal project that no one else is supposed to use, I’m not sure why it’s on HN. Those are totally fine on HN too.

Except the title (previously) said homebrew replacement. So when it doesn’t say why/what, and there’s no context, people are going to be confused.

Sometimes titles are slightly wrong. It's just not that big of a deal, most of the time. It's a messageboard in large part about the pleasure of finding things out rather than the grump of not everything being exactly as you expect.

Re: Sapphire: Rust based package manager for macOS

#283

Earlier quoted context omitted.

I think you mean “the hell I got from the team”. I wonder if anything changed substantially over the years to make you say that?

I feel like it's quite rude to deny to someone's lived experience and then ask what might have changed to make them feel that way.

[deleted]

Re: Sapphire: Rust based package manager for macOS

#284

Earlier quoted context omitted.

It's not _just_ the infrastructure that is awesome for homebrew. The help I got from the team, answering in real-time when I didn't know how to get through the CI bugs is amazing. It's the boring maintainence work that makes it so special for me. I also feel that there could be a lot of automation in the backend part, catching bugs early (maybe even on local machine before CI run) for example.

I think you mean “the hell I got from the team”. I wonder if anything changed substantially over the years to make you say that?

To those who downvote, care to explain? Homebrew community is notorious in how they treat users on their GitHub Issues and I wonder why anyone is downvoting without showing how that situation have changed.

Re: Sapphire: Rust based package manager for macOS

#285
post #26

Hey, so I built this thing, most of it at so far at least. And yeah, right now it isn't doing many things better than Homebrew. Setting of relative paths for bottle installs is still not perfect, well it works for every bottle I have tested except rust. Getting bottles working 100% is very doable though imo. Build from source formulae is still pretty f*ed + I do not know if it is really feasible given that the json A…

> Build from source formulae is still pretty f*ed + I do not know if it is really feasible given that the json API lacks information there and a full on Ruby -> Rust transpiler is way out of scope. Will probably settle for automatic build system detection based on archive structure there. + Maybe do my own version of the .rb scripts but in a more general machine readable format, not .rs lol

Last I checked (which was about a year ago), Homebrew had ~7000 formulas (not including casks).

I think it would be feasible to transcribe most of them to your format of choice with AI, run the build in a loop and ask the LLM to fix errors, and reserve manual intervention for the few cases that the LLM can't fix.

Re: Sapphire: Rust based package manager for macOS

#286
post #259

Earlier quoted context omitted.

> not dependencies for your own Python projects I'm not doing that. Honestly I'm not sure how to do that and it sounds like a real pain. > the Python version does not matter This is incorrect. Go check what versions of Python brew has installed for you. It's definitely not your system version... It's not "what works" it is "what the maintainer specified". And according to the brew devs this is supposed to be /the lat…

My experience was actually the opposite -- a package I used broke because somebody did an automated "bump the python version this package uses" change without noticing that upstream for the package hadn't yet made a release with the necessary changes to make it work with that python version, so it fell over on startup. (They were quick with reverting it when I reported the problem.)

That happens too. But that's normal bugs.

For the issue I'm talking about you have to look. It's a non breaking bug. So unless you look you likely won't see the problem.

That's two types of bugs: 1) Those that scream at you 2) Those that hide. We're talking about by later

Re: Sapphire: Rust based package manager for macOS

#287
post #56

Earlier quoted context omitted.

What makes you interested in a rust implementation of brew? I'm guessing it's that you hoping that it is eventually more performant -- are there specific areas of current brew you have identified as performance bottlenecks likely to eventually benefit from a rust implementation? Or any more info to share about assumptions/hopes that motivated this or any other motivations?

I say this from ignorance, but coming from a lineage of linux package managers; brew must be doing something wrong - and upon immediate introspection I doubt that its language specific. The performance of apt/dnf in comparison is surreal; but dnf (or at least yum, its predecessor) is written in Python; which has even worse performance characteristics than Ruby. Clearly something is wrong, I wonder how different they…

FWIW, I believe DNF (as of 5?) is now written in C++.

But as a long time Linux user who always has to use a Mac at work I've been consistently floored by how painful Homebrew is to use, to the point that for my latest corp-issued MacBook I switched to home-manager and I'm not looking back.

Re: Sapphire: Rust based package manager for macOS

#288

Earlier quoted context omitted.

> not dependencies for your own Python projects I'm not doing that. Honestly I'm not sure how to do that and it sounds like a real pain. > the Python version does not matter This is incorrect. Go check what versions of Python brew has installed for you. It's definitely not your system version... It's not "what works" it is "what the maintainer specified". And according to the brew devs this is supposed to be /the lat…

I don't follow the argument here: * One of the main reasons Homebrew doesn't use the "system" Python is because Apple has repeatedly indicated that they want to remove it, and that integrators should not depend on it. This, plus per-package Python version requirements makes using a single system Python a non-starter. * The "bloat" you're noting in Homebrew around multiple Python interpreters is present in `uv` and `p…

  > because Apple has repeatedly indicated that they want to remove it
That's not a reason to not use it. There's absolutely zero reason for me to have two copies of an exact same Python version (e.g 3.11.4). There is rarely reason to have a differing subversions (3.11.3 vs 3.11.4).

  > is present in `uv`
Are you guessing or do you know? Try it out. Prove me wrong.

I said they search for versions on your system and link if found. Seriously, look into it

  > disk space is cheap
That's not correct. It's a thing you need to consider when you have to compromise but not an infinite resource. But there's something cheaper than storage: infrequently scanning the system!

The problem is when everyone thinks this way then space is no longer cheap (especially with Apple!)

Tragedy of the commons

In fact it's a big reason I live in the terminal. Because even on a modern M2 air that bloat creeps in. My system is fast and snappy. I have plenty of storage. But this isn't true if I didn't. The creep still happens in these programs but their nature lessens the blows and the likelihood that people care about these things increases.

Re: Sapphire: Rust based package manager for macOS

#289
post #26

Hey, so I built this thing, most of it at so far at least. And yeah, right now it isn't doing many things better than Homebrew. Setting of relative paths for bottle installs is still not perfect, well it works for every bottle I have tested except rust. Getting bottles working 100% is very doable though imo. Build from source formulae is still pretty f*ed + I do not know if it is really feasible given that the json A…

> Build from source formulae is still pretty f*ed + I do not know if it is really feasible given that the json API lacks information there and a full on Ruby -> Rust transpiler is way out of scope. Will probably settle for automatic build system detection based on archive structure there. + Maybe do my own version of the .rb scripts but in a more general machine readable format, not .rs lol Last I checked (which was…

Yeah, this would 100% be feasible. Great idea. It's during the week now so I don't have much time besides work.

I'll probably open a Poll on git within the next couple days about what to do about a real from source packaging system with it's own dsl, maybe just yaml/toml or something a bit more powerful like lua with mlua. No matter the choice of packaging apporach I would like to keep the generated packages "bottle compliant" -> at least with the json api spec, since this also installs from there.

There seems to be at least some in my project so even though I am very opinionated on a lot of things I don't think I should decide on that completely alone, especially given that this is the first time I play with packaging.

Re: Sapphire: Rust based package manager for macOS

#290

Earlier quoted context omitted.

> Build from source formulae is still pretty f*ed + I do not know if it is really feasible given that the json API lacks information there and a full on Ruby -> Rust transpiler is way out of scope. Will probably settle for automatic build system detection based on archive structure there. + Maybe do my own version of the .rb scripts but in a more general machine readable format, not .rs lol Last I checked (which was…

Yeah, this would 100% be feasible. Great idea. It's during the week now so I don't have much time besides work. I'll probably open a Poll on git within the next couple days about what to do about a real from source packaging system with it's own dsl, maybe just yaml/toml or something a bit more powerful like lua with mlua. No matter the choice of packaging apporach I would like to keep the generated packages "bottle…

on github xD
Post reply on HN