Insert before encrypt
This commit is contained in:
parent
d40d1e4aa6
commit
5e37bab6be
|
@ -100,7 +100,7 @@ fi
|
|||
chown -R $MYUSERNAME:$MYUSERNAME $LISTDIR
|
||||
|
||||
if ! grep -q "Subject:.*()\[$SUBJECTTAG\]" $PM; then
|
||||
if ! grep -q "End of rule" $PM; then
|
||||
if ! grep -q "\# encrypt" $PM; then
|
||||
echo "" >> $PM
|
||||
echo "/# Email rule for $MAILINGLIST subject \[$SUBJECTTAG\]" >> $PM
|
||||
echo ":0" >> $PM
|
||||
|
@ -109,12 +109,13 @@ if ! grep -q "Subject:.*()\[$SUBJECTTAG\]" $PM; then
|
|||
echo "/# End of rule" >> $PM
|
||||
chown $MYUSERNAME:$MYUSERNAME $PM
|
||||
else
|
||||
sed -i "/End of rule/a
|
||||
sed -i "/\# encrypt/i
|
||||
/# Email rule for $MAILINGLIST subject \[$SUBJECTTAG\]
|
||||
:0
|
||||
* ^Subject:.*()\[$SUBJECTTAG\]
|
||||
$LISTDIR/new
|
||||
/# End of rule" $PM
|
||||
/# End of rule
|
||||
" $PM
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in New Issue