So, I have the sieve working up to the point that it calls the script, and the 
script is called (I get different errors if the script is not there, for 
example).

filter action
  execute program `darkmode.sh'
  [[EXECUTION ABORTED]]

There's no other error logged (for example, when I had sieve_filter_bin_dir 
miss-set, I would get: 

sieve: action filter: failed to execute program `darkmode.sh': 
vnd.dovecot.filter extension is unconfigured

In /var/log/messages, but I fixed that.

I assume there is something wrong with what I am doing in the script, bit that 
is something I am not finding any examples on that are proving useful.

The script file is simply:

Darkmode.sh:
#!/bin/sh
echo $1 | sed -e '|</head>|<style>* {color:white !important; background-color: 
black !important; } </style></head>|'

Which is somehwat similar to a working script for reporting spam:

sa-learn-spam.sh:
#!/bin/sh
exec /usr/local/bin/sa-learn -u ${1} --spam


-- 
"Are you pondering what I'm pondering?"
"I think so, Brain, but won't it go straight to my hips?!"

Reply via email to