On Sat, 20 Jul 2002, Glenn Carver wrote:
> Thanks for your email. There's a typo in the exim 4 FAQ for Q9807 (as
> well as the lack of allow_defer).
Thanks. Both fixed in the newly released version.
> Just out of curiousity, suppose I wanted to defer a message based on
> the time-of-day and only attempt delivery after 2am. I've seen the
> $tod variables but I'd need a bit of regex to strip out and test just
> the hour of the day. And I'm not a regex wiz.. how would I do it?
${if match{$tod_log}{\N^.{11}(\d\d)\N}{$1}}
expands to the hour of the day. Thus, a condition that yields "yes"
between the hours of 2 am and 8 am is:
condition = ${if and \
{ \
{ > \
{${if match{$tod_log}{\N^.{11}(\d\d)\N}{$1}}} \
{2} \
} \
{ < \
{${if match{$tod_log}{\N^.{11}(\d\d)\N}{$1}}} \
{8} \
} \
} \
{yes}{no}}
--
Philip Hazel University of Cambridge Computing Service,
ph10@??? Cambridge, England. Phone: +44 1223 334714.