[exim] Exim filters: converting strings to numbers?

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Adam Funk
Fecha:  
A: exim-users
Asunto: [exim] Exim filters: converting strings to numbers?
I'm learning to set up Exim filters for sorting mail into Maildir
folders on my shell account. The hosting company already applies spam
scores to my incoming mail and adds (for example)

X-Blackcat-Spam-Score:    30.9
  or
X-Blackcat-Spam-Score:    1.1
  or
X-Blackcat-Spam-Score:    -2.1


to each message. I want to write a condition to filter on this but I
can't find in the documentation how to convert the string content of
the header $h_Blackcat-Spam-Score: to a numeric value to use in a
condition like this:

...
elif
_SCORE_ is above 9.5
then
save $home/Maildir/.spam/
...

then I'll tweak the threshold until I get the filtering level I want.


Is conversion automatic? Can I just write

$h_Blackcat-Spam-Score: is above 9.5

or have I missed something in the docs?


Thanks,
Adam