diff options
| author | mailman | 1998-05-26 03:07:12 +0000 |
|---|---|---|
| committer | mailman | 1998-05-26 03:07:12 +0000 |
| commit | a0da2180a78a7954705ddd5eaf92fa09bf829c81 (patch) | |
| tree | a3998991c5c6b1f0df6e9c1f80a03c8b654eb8bd | |
| parent | 2f8aee333c15ef55e81d1702c9c477f688221d10 (diff) | |
| download | mailman-a0da2180a78a7954705ddd5eaf92fa09bf829c81.tar.gz mailman-a0da2180a78a7954705ddd5eaf92fa09bf829c81.tar.zst mailman-a0da2180a78a7954705ddd5eaf92fa09bf829c81.zip | |
Complain and bail if the list was specified with an '@' - don't let
the operator make the mistake of specifying the list's address...
| -rwxr-xr-x | bin/newlist | 8 |
1 files changed, 7 insertions, 1 deletions
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 |
