Przeglądaj źródła

Change terminology from mailing list to group

Bob Mottram 10 lat temu
rodzic
commit
8f5be8cdfe

+ 3
- 3
doc/EN/usage.org Wyświetl plik

@@ -239,15 +239,15 @@ exit
239 239
 
240 240
 The subject tag should be the word or phrase which appears within the brackets in the subject line of emails from the mailing list. The mailing list name should be something short so that it is readable within the left side column of the mutt email client, and contain no spaces.
241 241
 ** Adding email addresses to a group/folder
242
-Similar to adding mailing list folders you can also add specified email addresses into a folder.
242
+Similar to adding mailing list folders you can also add specified email addresses into a group/folder.
243 243
 
244 244
 #+BEGIN_SRC bash
245 245
 ssh username@domainname -p 2222
246
-freedombone-addemail -e <email address> -l <mailing list name>
246
+freedombone-addemail -e <email address> -g <group name>
247 247
 exit
248 248
 #+END_SRC
249 249
 
250
-The mailing list name should be something short so that it is readable within the left side column of the mutt email client, and not contain any spaces.
250
+The group name should be something short so that it is readable within the left side column of the mutt email client, and not contain any spaces.
251 251
 
252 252
 ** Ignoring incoming emails
253 253
 It is possible to ignore incoming emails if they are from a particular email address or if the subject line contains particular text.

BIN
man/freedombone-addemail.1.gz Wyświetl plik


+ 11
- 11
src/freedombone-addemail Wyświetl plik

@@ -31,11 +31,11 @@
31 31
 
32 32
 MYUSERNAME=$USER
33 33
 EMAILADDRESS=
34
-MAILINGLIST=
34
+GROUP_NAME=
35 35
 
36 36
 function show_help {
37 37
     echo ''
38
-    echo 'freedombone-addemail -u [username] -e [email address] -l [mailing list name]'
38
+    echo 'freedombone-addemail -u [username] -e [email address] -g [group name]'
39 39
     echo ''
40 40
     exit 0
41 41
 }
@@ -56,9 +56,9 @@ case $key in
56 56
     shift
57 57
     EMAILADDRESS="$1"
58 58
     ;;
59
-    -l|--list)
59
+    -g|--group)
60 60
     shift
61
-    MAILINGLIST="$1"
61
+    GROUP_NAME="$1"
62 62
     ;;
63 63
     *)
64 64
     # unknown option
@@ -67,13 +67,13 @@ esac
67 67
 shift
68 68
 done
69 69
 
70
-if ! [[ $MYUSERNAME && $EMAILADDRESS && $MAILINGLIST ]]; then
70
+if ! [[ $MYUSERNAME && $EMAILADDRESS && $GROUP_NAME ]]; then
71 71
     show_help
72 72
 fi
73 73
 
74 74
 MUTTRC=/home/$MYUSERNAME/.muttrc
75 75
 PM=/home/$MYUSERNAME/.procmailrc
76
-LISTDIR=/home/$MYUSERNAME/Maildir/$MAILINGLIST
76
+LISTDIR=/home/$MYUSERNAME/Maildir/$GROUP_NAME
77 77
 
78 78
 if [ ! -d "$LISTDIR" ]; then
79 79
     mkdir -m 700 $LISTDIR
@@ -82,8 +82,8 @@ if [ ! -d "$LISTDIR" ]; then
82 82
     mkdir -m 700 $LISTDIR/cur
83 83
 fi
84 84
 chown -R $MYUSERNAME:$MYUSERNAME $LISTDIR
85
-if ! grep -q "Email rule for $EMAILADDRESS -> $MAILINGLIST" $PM; then
86
-    echo "# Email rule for $EMAILADDRESS -> $MAILINGLIST" >> $PM
85
+if ! grep -q "Email rule for $EMAILADDRESS -> $GROUP_NAME" $PM; then
86
+    echo "# Email rule for $EMAILADDRESS -> $GROUP_NAME" >> $PM
87 87
     echo ":0" >> $PM
88 88
     echo "  * ^From:.*$EMAILADDRESS" >> $PM
89 89
     echo "$LISTDIR/new" >> $PM
@@ -100,9 +100,9 @@ if [ ! -d $PROCMAILLOG ]; then
100 100
   chown -R $MYUSERNAME:$MYUSERNAME $PROCMAILLOG
101 101
 fi
102 102
 MUTT_MAILBOXES=$(grep "mailboxes =" $MUTTRC)
103
-if [[ $MUTT_MAILBOXES != *$MAILINGLIST* ]]; then
104
-  if ! grep -q "=$MAILINGLIST" $MUTTRC; then
105
-    sed -i "s|$MUTT_MAILBOXES|$MUTT_MAILBOXES =$MAILINGLIST|g" $MUTTRC
103
+if [[ $MUTT_MAILBOXES != *$GROUP_NAME* ]]; then
104
+  if ! grep -q "=$GROUP_NAME" $MUTTRC; then
105
+    sed -i "s|$MUTT_MAILBOXES|$MUTT_MAILBOXES =$GROUP_NAME|g" $MUTTRC
106 106
     chown $MYUSERNAME:$MYUSERNAME $MUTTRC
107 107
   fi
108 108
 fi

+ 0
- 1
src/freedombone-rmemail Wyświetl plik

@@ -30,7 +30,6 @@
30 30
 # along with this program. If not, see <http://www.gnu.org/licenses/>.
31 31
 
32 32
 MYUSERNAME=$USER
33
-MAILINGLIST=
34 33
 
35 34
 function show_help {
36 35
     echo ''

+ 4
- 4
website/EN/usage.html Wyświetl plik

@@ -4,7 +4,7 @@
4 4
 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
5 5
 <head>
6 6
 <title></title>
7
-<!-- 2015-04-05 Sun 12:59 -->
7
+<!-- 2015-04-05 Sun 13:07 -->
8 8
 <meta  http-equiv="Content-Type" content="text/html;charset=utf-8" />
9 9
 <meta  name="generator" content="Org-mode" />
10 10
 <meta  name="author" content="Bob Mottram" />
@@ -720,19 +720,19 @@ The subject tag should be the word or phrase which appears within the brackets i
720 720
 <h3 id="unnumbered-18">Adding email addresses to a group/folder</h3>
721 721
 <div class="outline-text-3" id="text-unnumbered-18">
722 722
 <p>
723
-Similar to adding mailing list folders you can also add specified email addresses into a folder.
723
+Similar to adding mailing list folders you can also add specified email addresses into a group/folder.
724 724
 </p>
725 725
 
726 726
 <div class="org-src-container">
727 727
 
728 728
 <pre class="src src-bash">ssh username@domainname -p 2222
729
-freedombone-addemail -e &lt;email address&gt; -l &lt;mailing list name&gt;
729
+freedombone-addemail -e &lt;email address&gt; -g &lt;group name&gt;
730 730
 <span class="org-keyword">exit</span>
731 731
 </pre>
732 732
 </div>
733 733
 
734 734
 <p>
735
-The mailing list name should be something short so that it is readable within the left side column of the mutt email client, and not contain any spaces.
735
+The group name should be something short so that it is readable within the left side column of the mutt email client, and not contain any spaces.
736 736
 </p>
737 737
 </div>
738 738
 </div>