[pve-devel] Plan for (invasive) shrink of pve-manager git repository

Fiona Ebner f.ebner at proxmox.com
Tue May 30 10:36:54 CEST 2023


Am 28.05.23 um 20:38 schrieb Thomas Lamprecht:
> If you fetch in an existing pve-manager.git repository you'll see something like:
> From git://git.proxmox.com/git/pve-manager
>  + f548e4fca...4a8501a8b master     -> origin/master  (forced update)
>  + 40ccc11c4...d26a7c43e stable-3   -> origin/stable-3  (forced update)
>  + 08ba4d2dd...789b4067b stable-4   -> origin/stable-4  (forced update)
>  + d0ec33c69...b80838a2f stable-5   -> origin/stable-5  (forced update)
>  + 6ba2c0bcf...b31a318d0 stable-6   -> origin/stable-6  (forced update)
> 
> For re-aligning your local master branch you can do a hard-reset, BUT check
> if you got any local commits yet (move them over to another branch with e.g.
> `git checkout -b feature-to-re-apply-on-master`
> 
> git checkout master
> git reset --hard origin/master
> 
> Then re-create your active development branches freshly from the master
> and cherry-pick the relevant patches from the old branch.
> 
> After that you can delete the old branches.
> 

Just a small addendum, because my repository was still pretty large
after the above. I had to remove stale remote branches, which can be
done with e.g. 'git fetch --all --prune' and I had to run 'git stash
clear'. Only then my repository shrunk below 260 MiB. You also might
want to check for tags that could still be referencing old stuff.





More information about the pve-devel mailing list