its definitely worth supporting for git servers designed to work with nostr. Its just widespread support is probably unlikely. Its a little but uncertain the extent to which repositories that use nostr will use free-to-host git servers (ie remain on github) vs using bespoke solutions like song or ghole. I did some tests with native git options if `git archive`. Its probably then worth having a stateful proxy service that serves from a cache of repositories. ``` git clone --no-checkout --filter=tree:0 cd bitcoin git restore --staged README.md git checkout README.md ``` 3 calls - 28.44mb + 88kb + 1.57kb ``` git clone --no-checkout --filter=blob:none cd bitcoin git restore --staged README.md git checkout README.md ``` 2 calls - 55.46mb + 1.57kb ``` git clone --no-checkout cd bitcoin git restore --staged README.md git checkout README.md ``` 1 calls - 247.66mb

Replies (2)

Its probably a much better UX to enable browsing of directories, files and commits / branches and states at different commit histories. In which case you would need to do some sort of a clone anyway.
We discussed it back in March and here are some numbers for the bitcoin core repo: View quoted note → tbh those numbers are not that big. last time I checked, git implementations in the browser don't support these advanced flags. doing a full clone automatically in the browser is probably a bad idea as it is unfair on those who are bandwidth constrained. But this could be done statelessly on a server fairly quickly. bandwidth on a VPS is probably quite cheap these days so if traffic volumes were low it shouldn't be too expensive. Depending on the bandwidth vs storage costs it could be worth storing a clone of repositories and using that instead. That way it would be easier, or cheaper per interaction, to allow browsing commits, metadata, etc. From a decentralisation point of view, I could build `ngit serve` which could be used instead (even in offline scenarios) instead of the proxy.