Mercurial > hg
comparison mercurial/dispatch.py @ 9825:0d850f8beea6
dispatch: better error message for --config option
author | Bill Schroeder <bschroeder@allstontrading.com> |
---|---|
date | Wed, 04 Nov 2009 13:44:15 -0600 |
parents | a1943c2a4661 |
children | d6a95c5f6ff9 8bce1e0d2801 |
comparison
equal
deleted
inserted
replaced
9824:87c92b260710 | 9825:0d850f8beea6 |
---|---|
277 section, name = name.split('.', 1) | 277 section, name = name.split('.', 1) |
278 if not section or not name: | 278 if not section or not name: |
279 raise IndexError | 279 raise IndexError |
280 ui.setconfig(section, name, value) | 280 ui.setconfig(section, name, value) |
281 except (IndexError, ValueError): | 281 except (IndexError, ValueError): |
282 raise util.Abort(_('malformed --config option: %s') % cfg) | 282 raise util.Abort(_('malformed --config option: %r ' |
283 '(use --config section.name=value)') % cfg) | |
283 | 284 |
284 def _earlygetopt(aliases, args): | 285 def _earlygetopt(aliases, args): |
285 """Return list of values for an option (or aliases). | 286 """Return list of values for an option (or aliases). |
286 | 287 |
287 The values are listed in the order they appear in args. | 288 The values are listed in the order they appear in args. |