cmaitchison/git_diet

Deleting older versions of files

bfulop opened this issue · 3 comments

Is there a way that I could tell your script to delete older versions only (5 or commits back) of the largest files it found?

I'm working with a lot of image files and I never needed to restore a very old version, but they're eating up a lot of space on my repo.

I'm not sure this is the best way to contact the author. I'm new to Github and I couldn't find another way.

Thanks!

That's a tough one!

It's a good use case, and hopefully someone with the git-fu to do it forks the repo and takes a crack at it.

On 09/05/2012, at 9:35 PM, bfulop wrote:

Is there a way that I could tell your script to delete older versions only (5 or commits back) of the largest files it found?

I'm working with a lot of image files and I never needed to restore a very old version, but they're eating up a lot of space on my repo.

I'm not sure this is the best way to contact the author. I'm new to Github and I couldn't find another way.

Thanks!


Reply to this email directly or view it on GitHub:
#3

Maybe this could be a workable solution?

http://stackoverflow.com/questions/930612/git-remove-oldest-revisions-of-a-file/931054#931054

I might try to integrate this to your script one day, but I'm not really familiar with shell scripts.

Thanks for the reply! At least I know that it's not that trivial!

Great i use this right now with minor modification on fedora20

sh find_fattest_objects.sh -n25 -d -f | xargs sh purge_objects.sh

working fine, thanks !