~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/repofmt/weaverepo.py

Only chown() the .bzr.log when creating it, fixing NEWS entry to put it under 2.2b3

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2007-2010 Canonical Ltd
 
1
# Copyright (C) 2005, 2006, 2007, 2008 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
39
39
    lockdir,
40
40
    osutils,
41
41
    revision as _mod_revision,
42
 
    trace,
43
42
    urlutils,
44
43
    versionedfile,
45
44
    weave,
54
53
    RepositoryFormat,
55
54
    )
56
55
from bzrlib.store.text import TextStore
 
56
from bzrlib.trace import mutter
57
57
from bzrlib.tuned_gzip import GzipFile, bytes_to_gzip
58
58
from bzrlib.versionedfile import (
59
59
    AbsentContentFactory,
106
106
    def _all_possible_ids(self):
107
107
        """Return all the possible revisions that we could find."""
108
108
        if 'evil' in debug.debug_flags:
109
 
            trace.mutter_callsite(
110
 
                3, "_all_possible_ids scales with size of history.")
 
109
            mutter_callsite(3, "_all_possible_ids scales with size of history.")
111
110
        return [key[-1] for key in self.inventories.keys()]
112
111
 
113
112
    @needs_read_lock
177
176
        :param new_value: True to restore the default, False to disable making
178
177
                          working trees.
179
178
        """
180
 
        raise errors.RepositoryUpgradeRequired(self.user_url)
 
179
        raise errors.RepositoryUpgradeRequired(self.bzrdir.root_transport.base)
181
180
 
182
181
    def make_working_trees(self):
183
182
        """Returns the policy for making working trees on new branches."""
200
199
    def _all_possible_ids(self):
201
200
        """Return all the possible revisions that we could find."""
202
201
        if 'evil' in debug.debug_flags:
203
 
            trace.mutter_callsite(
204
 
                3, "_all_possible_ids scales with size of history.")
 
202
            mutter_callsite(3, "_all_possible_ids scales with size of history.")
205
203
        return [key[-1] for key in self.inventories.keys()]
206
204
 
207
205
    @needs_read_lock
288
286
        weavefile.write_weave_v5(weave.Weave(), sio)
289
287
        empty_weave = sio.getvalue()
290
288
 
291
 
        trace.mutter('creating repository in %s.', a_bzrdir.transport.base)
 
289
        mutter('creating repository in %s.', a_bzrdir.transport.base)
292
290
 
293
291
        # FIXME: RBC 20060125 don't peek under the covers
294
292
        # NB: no need to escape relative paths that are url safe.
528
526
        weavefile.write_weave_v5(weave.Weave(), sio)
529
527
        empty_weave = sio.getvalue()
530
528
 
531
 
        trace.mutter('creating repository in %s.', a_bzrdir.transport.base)
 
529
        mutter('creating repository in %s.', a_bzrdir.transport.base)
532
530
        dirs = ['revision-store', 'weaves']
533
531
        files = [('inventory.weave', StringIO(empty_weave)),
534
532
                 ]