From 3a673a7591aac21ad9800bf9e4d3d9cf2ac12f3e Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Sat, 1 Nov 2014 15:41:07 +0100 Subject: email2irc: the email-ext plugin sometimes sends multi line subjects - deal with it --- bin/email2irc.sh | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'bin/email2irc.sh') diff --git a/bin/email2irc.sh b/bin/email2irc.sh index 294fcbfa..8633dd0f 100755 --- a/bin/email2irc.sh +++ b/bin/email2irc.sh @@ -29,6 +29,11 @@ while read line ; do # catch Subject (to send to IRC later) if [[ $line =~ ^(Subject: .*) ]] ; then SUBJECT=${line:9} + # the email-ext plugin sometimes sends multi line subjects.. + NEXT=read line + if [ "${NEXT:1}" = " " ] ; then + SUBJECT="${SUBJECT}${NEXT}" + fi fi # determine the channel to send notifications to # by parsing the To: line -- cgit v1.2.3-54-g00ecf