From b8f74f5f857f54128b797a17f4f59f041eccfb7d Mon Sep 17 00:00:00 2001 From: William McBrine Date: Sat, 19 Sep 2009 22:37:41 -0400 Subject: [PATCH] Allow reading CR-delimited metadata files. Suggested by "jannlinder". --- metadata.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/metadata.py b/metadata.py index 044c307..2df2abb 100755 --- a/metadata.py +++ b/metadata.py @@ -121,7 +121,7 @@ def from_text(full_path): os.path.join(path, '.meta', name) + '.txt']: if os.path.exists(metafile): sep = ':='[metafile.endswith('.properties')] - for line in file(metafile): + for line in file(metafile, 'U'): if line.strip().startswith('#') or not sep in line: continue key, value = [x.strip() for x in line.split(sep, 1)] -- 2.11.4.GIT