Comments (1)
lazy fetch only needed files
this is solved in google's slothfs (aka gitfs), but only works with "Gerrit/Gitiles based Git hosting" = no github
background: access monorepos from thin clients
the tree contains a significant amount of unused data
no github
on github, we can use api.github.com
to browse commits and trees
and use raw.githubusercontent.com
to fetch blobs
this works well for small projects, where only few files are actually needed (syscalls: read, readdir, stat, attr)
for larger projects, this can be too slow, so git clone
becomes more attractive
pin git repo to commit hash
the goal here is file-deduplication on fat clients.
fat client = the full git repo was fetched with some depth (mostly-shallow clone),
so we have local access to old versions
what i want is something like this:
gitfs interface
/commit/:sha/tree/ -> root directory by commit sha
/tree/:sha/ -> root directory by tree sha (can be a subfolder of the repo)
/blob/:sha -> file by blob sha
sample:
$ gitfs mount https://github.com/presslabs/gitfs.git /tmp/demo
$ cd /tmp/demo
$ less commit/12886ec5b9c7e103bfcab0cd37a8333873382fae/tree/README.md
this would show exactly this file:
https://github.com/presslabs/gitfs/blob/12886ec5b9c7e103bfcab0cd37a8333873382fae/README.md
https://raw.githubusercontent.com/presslabs/gitfs/12886ec5b9c7e103bfcab0cd37a8333873382fae/README.md
from gitfs.
Related Issues (20)
- Ubuntu 20.04 HOT 10
- Document usage in Docker
- Update PyPI
- MacOS brew install gitfs fails HOT 2
- Support for pygit2 1.2 and libgit2 1.0.0
- Turn off history HOT 2
- File too large error - cannot edit any files HOT 1
- Simultaneous changes on different instances cause incorrect merge
- ssh key is hardcoded to use id_rsa HOT 1
- Dependabot couldn't authenticate with https://pypi.python.org/simple/
- Raven dependency is deprecated
- how to mount using fstab HOT 1
- brew install fails with 'gitfs has been disabled because it requires closed-source macFUSE!' HOT 5
- Renaming file fails in gitfs
- Python atomiclong seems to be discontinued HOT 1
- Request a new release HOT 2
- Can't install
- No documentation HOT 2
- Support for Windows 11? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gitfs.