On 30 Oct 2020, at 12:34, @lbutlr kremels@kreme.com wrote:
I am not sure about the $1. I think filter just pipes the message (or part of the message.
I will see what happens without the echo I suppose.
Nope, still the same.
32: starting
:contains' match with
i;ascii-casemap' comparator: 32: matching value<!DOCTYPE html><html lang="en"><head><title>29-Oct-2020 ""</title> <style>?? ...' 32: with key
</head>' => 1 32: finishing match with result: matched 32: jump if result is false 32: not jumping 34: filter action 34: execute program `darkmode.sh' 34: [[EXECUTION ABORTED]]
Here is the relevant part of doveconf -n
plugin { imapsieve_mailbox1_before = file:/usr/lib/dovecot/sieve/report-spam.sieve imapsieve_mailbox1_causes = COPY imapsieve_mailbox1_name = Junk imapsieve_mailbox2_before = file:/usr/lib/dovecot/sieve/report-ham.sieve imapsieve_mailbox2_causes = COPY imapsieve_mailbox2_from = Junk imapsieve_mailbox2_name = * imapsieve_mailbox3_before = file:/usr/lib/dovecot/sieve/mark-read.sieve imapsieve_mailbox3_causes = COPY imapsieve_mailbox3_name = Archive quota_rule2 = .EXPUNGED:ignore sieve = file:~/.sieve;active=~/.active_sieve sieve_before = file:/usr/lib/dovecot/sieve/bcc.sieve sieve_before3 = file:/usr/lib/dovecot/sieve/filespam.sieve sieve_default_name = spamassassin sieve_duplicate_default_period = 1h sieve_duplicate_max_period = 12d sieve_extensions = +vnd.dovecot.pipe +vnd.dovecot.environment +vnd.dovecot.filter +editheader sieve_filter_bin_dir = /usr/lib/dovecot/sieve /usr/local/virtual/ sieve_pipe_bin_dir = /usr/lib/dovecot/sieve sieve_plugins = sieve_imapsieve sieve_extprograms sieve_trace_dir = ~/.trace sieve_trace_level = matching sieve_user_log = ~/sieve.log }
Current shell script is
#!/bin/sh sed -e 's|</head>|<style>* {color:white !important; background-color: black !important; } </style></head>|'
exit 0
The script is in both the /usr/local/virtual/user/ with the .active_sieve and in /usr/lib/dovecot/sieve (unique files, not links, but identical).
-- 'It is always useful to face an enemy who is prepared to die for his country,' he read. 'This means that both you and he have exactly the same aim in mind.'