aboutsummaryrefslogtreecommitdiffstats
path: root/libbe/mapfile.py
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2009-08-31 13:16:48 -0400
committerW. Trevor King <wking@drexel.edu>2009-08-31 13:16:48 -0400
commit5e8576a48fae6e9f7a9699d57571e926d7e6e236 (patch)
tree82600e1eedbeb059cb03903fbbfa81be5778459e /libbe/mapfile.py
parent830522c293a479636d7bfc0fff125ec57f06e9a3 (diff)
downloadbugseverywhere-5e8576a48fae6e9f7a9699d57571e926d7e6e236.tar.gz
Upgrade duplicate bugdirs if necessary (e.g. for `be diff').
Also moved pre-YAML mapfile handling in mapfile.parse() into upgrade.Upgrade_1_0_to_2._upgrade_mapfile().
Diffstat (limited to 'libbe/mapfile.py')
-rw-r--r--libbe/mapfile.py18
1 files changed, 0 insertions, 18 deletions
diff --git a/libbe/mapfile.py b/libbe/mapfile.py
index b959d76..74d2b1a 100644
--- a/libbe/mapfile.py
+++ b/libbe/mapfile.py
@@ -95,24 +95,6 @@ def parse(contents):
>>> dict["e"]
'f'
"""
- old_format = False
- for line in contents.splitlines():
- if len(line.split("=")) == 2:
- old_format = True
- break
- if old_format: # translate to YAML. Hack to deal with old BE bugs.
- newlines = []
- for line in contents.splitlines():
- line = line.rstrip('\n')
- if len(line) == 0:
- continue
- fields = line.split("=")
- if len(fields) == 2:
- key,value = fields
- newlines.append('%s: "%s"' % (key, value.replace('"','\\"')))
- else:
- newlines.append(line)
- contents = '\n'.join(newlines)
return yaml.load(contents) or {}
def map_save(rcs, path, map, allow_no_rcs=False):