hydromt
hydromt copied to clipboard
reduce repos size by pruning history
The repository has grown quite big (>130MB) mainly because of large png and ipynb files in the documentation. There are some tools and guidelines to remove files from the git repository, but all should be used with utmost care! This is also best to execute at a moment when developments are frozen as everyone working on the repository will have to rebase their work after we have committed the purged history. There are also some options to not clone the full repos to make it a bit faster (but some come with limitations).
TODO:
- [ ] (short term) make sure that we do not longer commit large png files and remove executed ipynb from docs
- [ ] (to discuss) how many version of docs do we want to keep?
- [ ] (when we find a suitable timing) analyze and remove large files from history with git filter-repo, see also this git help
@visr Any experience with this or pointers to good references?
I haven't used git filter-repo, but I did use BFG once with success. Usually it's only a few files that make up the bulk of the size.
For the docs, probably it's enough to only keep the latest patch release of each breaking release, e.g. 0.1,0.2,0.3,0.4?
I've cleaned up the documentation branch history which did indeed make a big difference. It's still a bigger repository than I'd expect, but for now this should be okay, so I'll close this issue. We can open up another one in the future if necessary