/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/textinv.py

  • Committer: Vincent Ladeuil
  • Date: 2010-07-07 11:21:19 UTC
  • mto: (5193.7.1 unify-confs)
  • mto: This revision was merged to the branch mainline in revision 5349.
  • Revision ID: v.ladeuil+lp@free.fr-20100707112119-jwyh312df41w6l0o
Revert previous change as I can't reproduce the related problem anymore.

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program; if not, write to the Free Software
15
15
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16
16
 
17
 
from .errors import BzrError
18
 
from .inventory import Inventory
 
17
 
 
18
from bzrlib.errors import BzrError
 
19
from bzrlib.inventory import Inventory
19
20
 
20
21
 
21
22
START_MARK = "# bzr inventory format 3\n"
33
34
            .replace('\n', r'\x0a'))
34
35
 
35
36
 
 
37
 
36
38
def unescape(s):
37
39
    if s.find(' ') != -1:
38
40
        raise AssertionError()
46
48
    return s
47
49
 
48
50
 
 
51
 
 
52
 
49
53
def write_text_inventory(inv, outf):
50
54
    """Write out inv in a simple trad-unix text format."""
51
55
    outf.write(START_MARK)
81
85
              'name': unescape(fields[1]),
82
86
              'kind': fields[2],
83
87
              'parent_id': fields[3]}
84
 
        # inv.add(ie)
 
88
        ##inv.add(ie)
85
89
 
86
90
    if l != END_MARK:
87
91
        raise BzrError("missing end mark")