harmy / boar

Automatically exported from code.google.com/p/boar
0 stars 0 forks source link

Purge Directory from the Repo #22

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
This enhancement request is similar to Issue 13, but the idea would be to be 
able to strike an entire directory from the "snapshot" of a given session 
without disrupting the rest of the snapshot.

The use case is similar to that of issue 13. In the case of considerable 
reorganization of a media collection and particularly when a large directory is 
permanently removed from the collection and there is no longer a need/desire to 
maintain copies of that data, it would be nice to be able to remove a directory 
from a snapshot.

It would require iterating thru the bloblists of all linked sessions and 
removing any entries occurring at and below a given directory and removing 
blobs that are no longer present in any of the resulting bloblists.

To guard against corruption the linked sessions can first be cloned and the 
operation can be conducted on this clone to create a fork of the session.

In fact the "purge" command can simply handle the bloblist cleanup, while a 
second "cleanup" command can created to remove blobs that no longer have any 
entries in the bloblist.

Given that a guiding use case for boar is managing large media collections, 
being able to gracefully retire content from boar sessions/repos is important. 
I may upgrade all my music to a lossless format and decide to retire my "mp3" 
folder from my boar music repo for instance.

Anyway, I can't think of any obstacles that should make this too difficult to 
implement, however I've been wrong before... once ;)

Regardless, I think this is an important/desirable functionality for a tool 
like boar.

Original issue reported on code.google.com by in...@vittorio.me on 10 Jun 2011 at 1:09

GoogleCodeExporter commented 9 years ago
I agree that this is a desirable feature. While basically simple (remove the 
items from the bloblists and the data storage), it needs some thinking if it is 
to work well with the "clone" command for instance. 

One might however take the same course as Subversion. That is, permanent 
deletions are not a normal task, but the brave can still perform it somewhat 
easily by invasive surgery (like this: 
http://stackoverflow.com/questions/560684/svn-obliterate).

Original comment by ekb...@gmail.com on 21 Jun 2011 at 1:11