[MERGE] BzrDir.destroy_workingtree

Martin Pool mbp at canonical.com
Thu Sep 28 03:33:40 BST 2006


On 27 Sep 2006, Aaron Bentley <aaron.bentley at utoronto.ca> wrote:

> We need a way to destroy working trees without destroying their
> branches, for at least two purposes:
> 1. removing the working trees in repositories
> 2. implementing nested-by-value trees
> 
> BzrDir supports creating workingtrees, and opening them once created.
> So it seems consistent to destroy them that way, too.
> 
> What I'm implementing for nested-by-value trees is a 'join' command,
> which converts a subtree into part of the larger tree, while preserving
> history and setting parent_ids.  As part of the conversion, the subtree
> checkout metadata is deleted, while the file contents and branch are
> retained.

+1, seems reasonable.

I'd just raise a fairly minor question about the parameter to it though.  
Would this be happier as two methods, one of which destroys the files
and the other just removes the working tree control directory?  And, if
there is a parameter, does it really need to have a default value?
(It's probably fine actually, I just like to make sure default
parameters are justified.)


-- 
Martin




More information about the bazaar mailing list