~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/weavefile.py

add a clean target

Show diffs side-by-side

added added

removed removed

Lines of Context:
92
92
 
93
93
 
94
94
 
95
 
def read_weave(f,prelude=False):
96
 
    return read_weave_v5(f,prelude=prelude)
97
 
 
98
 
 
99
 
def read_weave_v5(f,prelude=False):
 
95
def read_weave(f):
 
96
    return read_weave_v5(f)
 
97
 
 
98
 
 
99
def read_weave_v5(f):
100
100
    from weave import Weave, WeaveFormatError
101
 
    w = Weave(getattr(f, 'name', None))
 
101
    w = Weave()
102
102
 
103
103
    l = f.readline()
104
104
    if l != FORMAT_1:
133
133
        else:
134
134
            raise WeaveFormatError('unexpected line %r' % l)
135
135
 
136
 
    if prelude:
137
 
        return w
138
 
 
139
136
    while True:
140
137
        l = f.readline()
141
138
        if l == 'W\n':