From a0da2180a78a7954705ddd5eaf92fa09bf829c81 Mon Sep 17 00:00:00 2001 From: mailman Date: Tue, 26 May 1998 03:07:12 +0000 Subject: Complain and bail if the list was specified with an '@' - don't let the operator make the mistake of specifying the list's address... --- bin/newlist | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bin/newlist b/bin/newlist index a995463e7..c2781f372 100755 --- a/bin/newlist +++ b/bin/newlist @@ -10,7 +10,7 @@ immediately. Otherwise, the script hangs pending input, to give time for the person creating the list to customize it before sending the admin an email notice about the existence of the new list.""" -__version__ = "$Revision: 515 $" +__version__ = "$Revision: 548 $" ADDALIASES_CMD = '/home/mailman/mailman/bin/addaliases' @@ -26,6 +26,12 @@ def main(argv): else: list_name = string.lower(raw_input("Enter the name of the list: ")) + if '@' in list_name: + sys.stderr.write("** List name must not include '@': %s\n" + % `list_name`) + sys.stderr.write(" (It's the list name, not address.)\n") + return 1 + if list_name in mm_utils.list_names(): sys.stderr.write("** List with name %s already exists\n" % `list_name`) return 1 -- cgit v1.3.1