this post was submitted on 06 Feb 2026
50 points (93.1% liked)
Technology
80724 readers
3614 users here now
This is a most excellent place for technology news and articles.
Our Rules
- Follow the lemmy.world rules.
- Only tech related news or articles.
- Be excellent to each other!
- Mod approved content bots can post up to 10 articles per day.
- Threads asking for personal tech support may be deleted.
- Politics threads may be removed.
- No memes allowed as posts, OK to post as comments.
- Only approved bots from the list below, this includes using AI responses and summaries. To ask if your bot can be added please contact a mod.
- Check for duplicates before posting, duplicates may be removed
- Accounts 7 days and younger will have their posts automatically removed.
Approved Bots
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I'm not going through the PR to understand what's breaking, since it's not immediately apparent from a quick skim. But three possible problems based on what people are mentioning there.
The problem is the cost of the shallow clone
Assuming that the workload here is always
--depth=1and they aren't doing commits at a high rate relative to clones, and that's an expensive operation for git, I feel like for GitHub, a better solution would be some patch to git that allows it to cache a shallow clone for depth=1 for a given hashref.The problem is the cost of unshallowing the shallow clone
If the actual problem isn't the shallow clone, that a regular clone would be fine, but that unshallowing is a problem, then a patch to git that allows more-efficient unshallowing should be a better solution. I mean, I'd think that unshallowing should only need a time-ordered index of commits referenced blobs up to a given point. That shouldn't be that expensive for git to maintain an index of, if it doesn't already have it.
The problem is that Homebrew has users repeatedly unshallowing a clone off GitHub and then blowing it away and repeating
If the problem is that people keep repeatedly doing a clone off GitHub
that is, a regular, non-shallow clone would also be problematic
I'd think that a better solution would be to have Homebrew do a local bare clone as a cache, and then just do a pull on that cache and then use it as a reference to create the new clone. If Homebrew uses the fresh clone as read-only and the cache can be relied upon to remain, then they could use
--referencealone. If not, then add--dissociate. I'd think that that'd lead to better performance anyway.