~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/workingtree_4.py

  • Committer: Aaron Bentley
  • Date: 2007-12-20 20:44:45 UTC
  • mto: This revision was merged to the branch mainline in revision 3235.
  • Revision ID: abentley@panoramicfeedback.com-20071220204445-9o2f10gvvd8e4rks
Implement hard-link support for branch and checkout

Show diffs side-by-side

added added

removed removed

Lines of Context:
1258
1258
        return "Working tree format 4"
1259
1259
 
1260
1260
    def initialize(self, a_bzrdir, revision_id=None, from_branch=None,
1261
 
                   accelerator_tree=None):
 
1261
                   accelerator_tree=None, hardlink=False):
1262
1262
        """See WorkingTreeFormat.initialize().
1263
1263
 
1264
1264
        :param revision_id: allows creating a working tree at a different
1267
1267
            contents more quickly than the revision tree, i.e. a workingtree.
1268
1268
            The revision tree will be used for cases where accelerator_tree's
1269
1269
            content is different.
 
1270
        :param hardlink: If true, hard-link files from accelerator_tree,
 
1271
            where possible.
1270
1272
 
1271
1273
        These trees get an initial random root id, if their repository supports
1272
1274
        rich root data, TREE_ROOT otherwise.
1327
1329
            if basis_root_id is not None:
1328
1330
                wt._set_root_id(basis_root_id)
1329
1331
                wt.flush()
1330
 
            transform.build_tree(basis, wt, accelerator_tree)
 
1332
            transform.build_tree(basis, wt, accelerator_tree,
 
1333
                                 hardlink=hardlink)
1331
1334
            basis.unlock()
1332
1335
        finally:
1333
1336
            control_files.unlock()