Abhishek Dasgupta wrote:
> Is there any way to drop a whole annex at a go? One way is of course
> by going to the annex I want to drop and doing a 'git annex drop .'
> 
> However, consider the hypothetical scenario: I have just lost my
> pendrive which had an annex; since I can't go back to it I can't drop
> all the files from there. git annex would keep on thinking that my pen
> drive exists.
> 
> Would removing all instances of the pendrive uuid from
> .git-annex/*.log make git-annex forget?

Let's assume your pendrive was using the WORM or SHA1 backend. Then yes,
as long as its UUID was in the log files, git-annex might suggest you
connect it, when you tried to get a file that the logs indicate was on it.
It would be easy to filter its UUID out of the log files to avoid that.
(A line of perl -i -pe, or a half an hour of haskell type errors should
yield a command to do it. ;) 

Or, you could just edit .git-annex/uuid.log to say:

203122bc-dc94-11df-80b7-002170d25c55 my long lost and lamented pen drive :(


A related situation is if you just:

git annex add $foo      && git commit -m added
git rm $foo             && git commit -m removed

Now there is a value in the backend that does not correspond to any
currently existing file in the annex. My plan has been to add some kind
of fsck command to check for those, and allow dropping them if desired.

Note that you might want to keep them -- for example, $foo might still
be present on another branch.

-- 
see shy jo

Attachment: signature.asc
Description: Digital signature

_______________________________________________
vcs-home mailing list
vcs-home@lists.madduck.net
http://lists.madduck.net/listinfo/vcs-home

Reply via email to