summaryrefslogtreecommitdiffstats
path: root/.config/dovecot
diff options
context:
space:
mode:
authorAmin Bandali <bandali@gnu.org>2022-12-24 23:30:19 -0500
committerAmin Bandali <bandali@gnu.org>2022-12-24 23:31:58 -0500
commitba6e420e8d84f3a09b519ebb81764bc63a3886cc (patch)
tree98cd53a6bb1d6950c9aeb8d581bcf998a0545692 /.config/dovecot
parent9b89e81900b1f45ef8bcecd25732e2b5f66df473 (diff)
downloadconfigs-ba6e420e8d84f3a09b519ebb81764bc63a3886cc.tar.gz
configs-ba6e420e8d84f3a09b519ebb81764bc63a3886cc.tar.xz
configs-ba6e420e8d84f3a09b519ebb81764bc63a3886cc.zip
Add some dovecot sieve rules
Diffstat (limited to '.config/dovecot')
-rw-r--r--.config/dovecot/canonical.sieve48
1 files changed, 48 insertions, 0 deletions
diff --git a/.config/dovecot/canonical.sieve b/.config/dovecot/canonical.sieve
new file mode 100644
index 0000000..70ffe5f
--- /dev/null
+++ b/.config/dovecot/canonical.sieve
@@ -0,0 +1,48 @@
+require [ "regex", "variables", "fileinto", "envelope", "mailbox",
+ "imap4flags", "include" ];
+
+if address :is "from" "noreply+chat@canonical.com" {
+ fileinto :create "mattermost";
+ stop;
+}
+
+if address :is "from" "noreply+discourse@canonical.com" {
+ fileinto :create "discourse";
+ stop;
+}
+
+if address :is :domain "from" ["discourse.ubuntu.com", "forum.snapcraft.io"] {
+ fileinto :create "discourse";
+ stop;
+}
+
+if address :is "from" "jira@warthogs.atlassian.net" {
+ fileinto :create "jira";
+ stop;
+}
+
+if address :is :domain "from" "rt.canonical.com" {
+ fileinto :create "rt";
+ stop;
+}
+
+if address :matches :domain "from" ["launchpad.net", "*.launchpad.net"] {
+ fileinto :create "launchpad";
+ stop;
+}
+
+if address :is "from" "gitlab@salsa.debian.org" {
+ fileinto :create "salsa";
+ stop;
+}
+
+if address :is "from" "notifications@github.com" {
+ keep;
+ stop;
+}
+
+if header :regex "list-id" "<([a-z_0-9-]+)[.@]" {
+ set :lower "listname" "${1}";
+ fileinto :create "l.${listname}";
+ stop;
+}