From 75941917d8c57b41e2583079f22863326ebf9920 Mon Sep 17 00:00:00 2001 From: Gurkirpal Date: Tue, 15 Mar 2016 19:03:21 +0530 Subject: Changed domain creation to True as default Added tests for domain option Updated docs for creating list from shell --- src/mailman/commands/cli_lists.py | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'src/mailman/commands/cli_lists.py') diff --git a/src/mailman/commands/cli_lists.py b/src/mailman/commands/cli_lists.py index 830d84470..035dce898 100644 --- a/src/mailman/commands/cli_lists.py +++ b/src/mailman/commands/cli_lists.py @@ -153,11 +153,20 @@ class Create: '-q', '--quiet', default=False, action='store_true', help=_('Print less output.')) - command_parser.add_argument( + domain_options = command_parser.add_mutually_exclusive_group() + domain_options.add_argument( '-d', '--domain', - default=False, action='store_true', + default=True, action='store_true', + help=_("""\ + Register the mailing list's domain if not yet registered."""), + dest='domain') + domain_options.add_argument( + '-D', '--no-domain', + default=False, action='store_false', help=_("""\ - Register the mailing list's domain if not yet registered.""")) + Do not register the mailing list's domain if not already registered."""), + dest='domain') + # Required positional argument. command_parser.add_argument( 'listname', metavar='LISTNAME', nargs=1, -- cgit v1.2.3-70-g09d2