Re: [exim] Quote problem with ${run}

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Stephan Helma
Dátum:  
Címzett: exim-users
Tárgy: Re: [exim] Quote problem with ${run}
Dear Graeme, dear Andreas,

Thanks for your answers!

${run {'/bin/date' '--date=2013-02-07' \
'+"%A, %-d %B"'}{$value}{$value}}

works. Unfortunately the quoting of each argument is not mentioned in
http://www.exim.org/exim-html-current/doc/html/spec_html/ch-string_expansions.html
And the default configuration file
/etc/exim4/conf.d/acl/30_exim4-config_check_rcpt has no single quotes in
the ${run command.

${run {/bin/date --date=2013-02-07 ${quote:+%A, %-d %B}}}

might work with exim -be, but not when the file is sourced in the
autoreply transport. Is this a bug?

I was not able loose the double quotes in the format string which end up
in the $value, but it is possible to remove them afterwards:

${sg { \
      ${run {'/bin/date' '--date=2013-02-07' '+"%A, %-d %B"'} \
            {$value} \
            {$value}}} \
      {"\n} \
      {}}
(This also removes the trailing newline.)


Stephan