NobGit
public nobgit read

NobMail

Based on mailcow: dockerized

Languages

Repository composition by tracked source files.

PHP
PHP 49% JavaScript 35% HTML 9% CSS 4% Shell 2% Python 1% Lua 0% Perl 0% Ruby 0% SCSS 0%
Create file Wiki Documentation
Clone
https://nobgit.com/orgs/nobgit/nobmail.git
ssh://[email protected]:2222/orgs/nobgit/nobmail.git

Commit

Sieve rule for tags changed

aa98d86f
andryyy <[email protected]> 9 years ago
data/conf/dovecot/sieve_after | 15 ++++++---------
 1 file changed, 6 insertions(+), 9 deletions(-)

Diff

diff --git a/data/conf/dovecot/sieve_after b/data/conf/dovecot/sieve_after
index 0b43dbcf..2e0cfe08 100644
--- a/data/conf/dovecot/sieve_after
+++ b/data/conf/dovecot/sieve_after
@@ -9,16 +9,13 @@ if header :contains "X-Spam-Flag" "YES" {
 }
 
 if allof (
-  envelope :detail :matches "to" "*",
-  header :contains "X-Moo-Tag" "YES",
-  mailboxexists "INBOX/${s}"
-  ) {
-    fileinto "INBOX/${s}";
-}
-elsif allof (
   envelope :detail :matches "to" "*",
   header :contains "X-Moo-Tag" "YES"
   ) {
-    set :lower "s" "${1}";
-    fileinto :create "INBOX/${s}";
+  set :lower :upperfirst "tag" "${1}";
+  if mailboxexists "INBOX/${1}" {
+    fileinto "INBOX/${1}";
+  } else {
+    fileinto :create "INBOX/${tag}";
+  }
 }