148
150
def _escape_path(self, path):
150
153
return unicode(path.replace('\\', '/').replace(' ', '\ '))
152
155
def _entry_to_line(self, path, ie):
153
156
"""Turn an inventory entry into a testament line"""
159
162
# TODO: avoid switching on kind
163
167
elif ie.kind == 'symlink':
165
170
content = self._escape_path(ie.symlink_target)
168
173
l = u' %s %s %s%s%s\n' % (ie.kind, self._escape_path(path),