mi...@bitblock.net writes:
Here's my line from maildrop - please ignore the line wrap - it's on one line: cc "| $MAILBOT -N -D 1 -d $UserFolder/BB-autoreply -t $UserFolder/BB- autoreply.txt -T replydsn -A\"From: $UI_Name <$UI_Email>\" -s\"Subject: AUTO- REPLY: (\$SUBJECT)\" -A\"Errors-To: nobody@nowhere\" -A\"Precedence: junk\" - A\"X-Loop: $BADLOOP\" /usr/local/bin/sendmail -f ''"I had tried -T reply too at some point though I don't think that would make a difference - trying replydsn was me being curious.When I trigger this the response I get is "AUTO-REPLY: ($SUBJECT)" so the shell expansion doesn't seem to be happening.Thanks again!
When you execute the following sequence of commands: $ SUBJECT="foobar" $ echo "--" -s"Subject: ($SUBJECT)" The resulting output is: -- -sSubject: (foobar)As you can see, the shell carries out variable substitution inside double- quotes.
If you can't figure this out, a workaround is to use an intermediate script file.
Sometimes when you have to execute a long, convoluted command with many variable expansions, it's easier to put the command into a separate script file, and execute the script file:
cc "| /etc/autoreply.sh"Then, put this long invocation of mailbot into the executable /etc/autoreply.sh file, where it gets involved with everything properly quoted. All of maildrop's variables should be available in the environment variables.
pgpc3IfTA9DMW.pgp
Description: PGP signature
------------------------------------------------------------------------------ Time is money. Stop wasting it! Get your web API in 5 minutes. www.restlet.com/download http://p.sf.net/sfu/restlet
_______________________________________________ courier-users mailing list courier-users@lists.sourceforge.net Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users