# HG changeset patch # User FUJIWARA Katsunori # Date 2011-11-24 08:54:50 # Node ID 6c5e6ebe08128c91ee3f6d1119bc3ce3ba836837 # Parent 3992c7df85f2e404ae24af721c9ef09d1cc830f4 largefiles: use "ui.configlist()" to get largefiles.patterns configuration current lfconvert implementation uses combination of "ui.config()" and "str.split(' ')" to get largefiles.patterns configuration. but it can not handle multiline configuration in hgrc files correctly. lfconvert should use "ui.configlist()" instead of it, as same as override_add does. diff --git a/hgext/largefiles/lfcommands.py b/hgext/largefiles/lfcommands.py --- a/hgext/largefiles/lfcommands.py +++ b/hgext/largefiles/lfcommands.py @@ -71,9 +71,7 @@ def lfconvert(ui, src, dest, *pats, **op lfiles = set() normalfiles = set() if not pats: - pats = ui.config(lfutil.longname, 'patterns', default=()) - if pats: - pats = pats.split(' ') + pats = ui.configlist(lfutil.longname, 'patterns', default=[]) if pats: matcher = match_.match(rsrc.root, '', list(pats)) else: diff --git a/tests/test-lfconvert.t b/tests/test-lfconvert.t --- a/tests/test-lfconvert.t +++ b/tests/test-lfconvert.t @@ -5,7 +5,8 @@ > graphlog = > [largefiles] > minsize = 0.5 - > patterns = **.dat + > patterns = **.other + > **.dat > EOF "lfconvert" works