report a bug |  advanced search |  statistics |  developer log in/out
Return to Bug #65
Patch mlmmj-make-ml-dol.patch revision 2018-01-16 17:21 UTC by zhb at iredmail dot org
revision 2017-08-27 20:51 UTC by zhb at iredmail dot org
Patch mlmmj-make-ml-do.patch revision 2017-08-27 20:34 UTC by zhb at iredmail dot org
Patch mlmmj-make-ml-d-man.patch revision 2017-08-27 17:30 UTC by zhb at iredmail dot org
Patch mlmmj-make-ml-d.patch revision 2017-08-27 08:49 UTC by zhb at iredmail dot org

Patch mlmmj-make-ml-do.patch for Generic Bug #65

Patch version 2017-08-27 20:34 UTC

Return to Bug #65 | Download this patch
This patch is obsolete

Obsoleted by patches:

This patch renders other patches obsolete

Obsolete patches:

Patch Revisions:

Developer: zhb@iredmail.org

--- src/mlmmj-make-ml.in.orig	2017-08-27 23:17:46.000000000 +0800
+++ src/mlmmj-make-ml.in	2017-08-27 23:28:43.000000000 +0800
@@ -12,13 +12,15 @@
              [-h] [-L listname] [-s spooldir] [-a] [-c user] [-z]
  -h: display this help text
  -L: the name of the mailing list
+ -d: the domain name part of the mailing list
  -s: your spool directory (default $DEFAULTDIR)
  -a: create the needed entries in your $ALIASFILE file
  -c: user to chown the spool directory to (default not to chown at all)
+ -o: email address of the list owner (default 'postmaster')
  -z: do nothing for now
 "
 
-while getopts ":hL:s:azc:" Option
+while getopts ":hL:s:azc:d:o:" Option
 do
 case "$Option" in 
 	h )
@@ -32,6 +34,9 @@
 	L )
 	LISTNAME="$OPTARG"
 	;;
+	d )
+	FQDN="$OPTARG"
+	;;
 	s )
 	SPOOLDIR="$OPTARG"
 	;;
@@ -42,6 +47,9 @@
 	DO_CHOWN=1
 	CHOWN="$OPTARG"
 	;;
+	o )
+	OWNER="$OPTARG"
+	;;
 	* )
 	echo "$0: invalid option"
 	echo "Try $0 -h for more information."
@@ -78,16 +86,20 @@
 
 test -f "$LISTDIR"/index || touch "$LISTDIR"/index
 
-echo -n "The Domain for the List? [] : "
-read FQDN
 if [ -z "$FQDN" ]; then
-	FQDN=`domainname -f`
+    echo -n "The Domain for the List? [] : "
+    read FQDN
+    if [ -z "$FQDN" ]; then
+        FQDN=`domainname -f`
+    fi
 fi
 
-echo -n "The emailaddress of the list owner? [postmaster] : "
-read OWNER
-if [ -z "$OWNER" ]; then
-	OWNER="postmaster"
+if [ -z $OWNER ]; then
+    echo -n "The emailaddress of the list owner? [postmaster] : "
+    read OWNER
+    if [ -z "$OWNER" ]; then
+        OWNER="postmaster"
+    fi
 fi
 echo "$OWNER" > "$LISTDIR"/"control/owner"
 
--- man/mlmmj-make-ml.1.orig	2017-08-27 23:29:20.000000000 +0800
+++ man/mlmmj-make-ml.1	2017-08-27 23:30:24.000000000 +0800
@@ -9,12 +9,16 @@
 .HP
 \fB\-L\fR: The name of the mailing list
 .HP
+\fB\-d\fR: The domain name part of the mailing list
+.HP
 \fB\-s\fR: Your spool directory (default /var/spool/mlmmj)
 .HP
 \fB\-a\fR: Create the needed entries in your /etc/aliases file
 .HP
 \fB\-c\fR: User to chown the spool directory to (default not to chown at all)
 .HP
+\fB\-o\fR: The email address of the list owner
+.HP
 \fB\-z\fR: Do nothing for now
 .SH DESCRIPTION
 This is an interactive script which creates the mailing list directory and thus
 
Based on the PHP bug tracker.
Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Wed Jan 30 01:27:44 2013 UTC