auto-update-daily-20260202
1local lib = import './gmailctl.libsonnet';
2
3local toMe = {
4 or: [
5 { to: 'vdemeest@redhat.com' },
6 { to: 'vdemeester@redhat.com' },
7 { to: 'vincent@sbr.pm' },
8 ],
9};
10local label_archive(filter, label) =
11 [
12 {
13 filter: filter,
14 actions: {
15 archive: true,
16 markSpam: false,
17 labels: [ label ]
18 }
19 }
20 ]
21;
22
23local rh_mailing_list(name, label = '', archive = true) =
24 local labels =
25 if label == '' then
26 [ std.join('/', std.splitLimit(name, '-', 1) ) ]
27 else
28 [ label ]
29 ;
30
31 [
32 {
33 filter: {
34 and: [
35 { list: name + '.redhat.com' },
36 ],
37 },
38 actions: {
39 archive: false,
40 markSpam: false,
41 labels: labels
42 }
43 },
44 {
45 filter: {
46 and: [
47 { list: name + '.redhat.com' },
48 { to: '-me' },
49 ],
50 },
51 actions: {
52 archive: archive,
53 markSpam: false,
54 labels: labels
55 }
56 }
57 ]
58;
59
60local google_groups(name, label = '', archive = true) =
61 local labels =
62 if label == '' then
63 [ std.join('/', std.splitLimit(name, '-', 1) ) ]
64 else
65 [ label ]
66 ;
67
68 [
69 {
70 filter: {
71 and: [
72 { list: name + '.googlegroups.com' },
73 ],
74 },
75 actions: {
76 archive: false,
77 markSpam: false,
78 labels: labels
79 }
80 },
81 {
82 filter: {
83 and: [
84 { list: name + '.googlegroups.com' },
85 { to: '-me' },
86 ],
87 },
88 actions: {
89 archive: archive,
90 markSpam: false,
91 labels: labels
92 }
93 }
94 ]
95;
96
97{
98 version: "v1alpha3",
99 author: {
100 name: "Vincent Demeester",
101 email: "vdemeest@redhat.com"
102 },
103 // Note: labels management is optional. If you prefer to use the
104 // GMail interface to add and remove labels, you can safely remove
105 // this section of the config.
106 rules: rh_mailing_list('announce-list', 'announce', false) +
107 rh_mailing_list('aos-announce', 'announce', false) +
108 rh_mailing_list('aos-devel') +
109 rh_mailing_list('aos-int-services') +
110 rh_mailing_list('aos-logging') +
111 rh_mailing_list('cloud-strategy', 'area/cloud-strategy') +
112 rh_mailing_list('france-list', '02-france', false) +
113 rh_mailing_list('france-associates', '02-france', false) +
114 rh_mailing_list('cdg', '02-france', false) +
115 rh_mailing_list('emea-announce', 'announce', false) +
116 rh_mailing_list('eng-common-logging', 'aos/eng-common-logging') +
117 rh_mailing_list('insights-dev') +
118 rh_mailing_list('insights-platform') +
119 rh_mailing_list('managers-announce') +
120 rh_mailing_list('managers-list', 'managers/managers-list') +
121 rh_mailing_list('memo-list', 'memo-list') +
122 rh_mailing_list('monitoring', 'monitoring') +
123 rh_mailing_list('openshift-announce', 'aos/openshift-announce') +
124 rh_mailing_list('openshift-sme', 'aos/openshift-sme') +
125 rh_mailing_list('pnt-managers', 'managers/pnt-managers') +
126 rh_mailing_list('prod-dept', 'pnt/prod-dept') +
127 rh_mailing_list('remote-announce', '02-remote', false) +
128 rh_mailing_list('remotees-list', '02-remote', false) +
129 rh_mailing_list('rh-openstack-announce', 'pnt/rh-openstack-announce') +
130 rh_mailing_list('summitdemo2019', 'pnt/summitdemo2019') +
131 rh_mailing_list('tech-talk-announce', 'announce/tech-talk') +
132 rh_mailing_list('technical-users-list', 'technical-users') +
133 rh_mailing_list('upshift', 'psi') +
134 rh_mailing_list('usa-announce', 'announce/usa') +
135 rh_mailing_list('all-sales', 'sales') +
136 rh_mailing_list('devtools-build') +
137 rh_mailing_list('devtools-deploy') +
138 rh_mailing_list('devtools-lead') +
139 rh_mailing_list('devtools-saas') +
140 rh_mailing_list('devtools-pm') +
141 rh_mailing_list('devtools-architects') +
142 rh_mailing_list('devtools-team', 'devtools') +
143 rh_mailing_list('devx', 'devtools/devx') +
144 rh_mailing_list('serverless-interests', 'serverless') +
145 rh_mailing_list('serverless-dev', 'serverless/dev') +
146 google_groups('knative-dev', 'knative/dev') +
147 google_groups('knative-users', 'knative/users') +
148 google_groups('istio-dev', 'istio/dev') +
149 google_groups('istio-users', 'istio/users') +
150 rh_mailing_list('pipelines-interests', '00-pipelines/interests') +
151 rh_mailing_list('pipelines-dev', '00-pipelines/dev', false) +
152 rh_mailing_list('pipelines-extcomm', '00-pipelines/dev', false) +
153 rh_mailing_list('pipelines-bots', '00-pipelines/bots', true) +
154 rh_mailing_list('konflux', '01-konflux', false) +
155 rh_mailing_list('konflux-announce', '01-konflux', false) +
156 google_groups('konflux', '01-konflux', false) +
157 google_groups('tekton-dev', '00-tekton/dev', false) +
158 google_groups('tekton-users', '00-tekton/users', false) +
159 google_groups('tekton-governance', '00-tekton/governance', false) +
160 google_groups('tekton-vmt', '00-tekton/vmt', false) +
161 google_groups('tekton-code-of-conduct', '00-tekton', false) +
162 rh_mailing_list('engineering-advocate', 'engineering-advocate') +
163 rh_mailing_list('engineering-advocate-nomination', 'engineering-advocate') +
164 google_groups('kubernetes-sig-cli', 'kubernetes/sig/cli') +
165 google_groups('operator-framework', 'operator/dev') +
166 google_groups('google-summer-of-code-mentors-list', 'gsoc/mentors') +
167 rh_mailing_list('cpaas-ops', '_tracker/cpaas') +
168 label_archive({from: 'do-not-reply@trello.com'}, '_tracker/trello') +
169 label_archive({from: 'help-ops@redhat.com'}, '_tracker/rh_service_now') +
170 # label_archive({from: 'hss-jira@redhat.com'}, '_tracker/jira') +
171 # label_archive({from: 'issues@jboss.org'}, '_tracker/jira') +
172 # label_archive({from: 'jira@jira.prod.coreos.systems'}, '_tracker/jira') +
173 label_archive({from: 'kundenservice@egencia.de'}, '_tracker/egencia') +
174 # label_archive({from: 'people-helpdesk@redhat.com'}, '_tracker/rh_service_now') +
175 # label_archive({from: 'redhat@service-now.com'}, '_tracker/rh_service_now') +
176 label_archive({from: 'workflow@redhat.com'}, '_tracker/ebs_workflow') +
177 label_archive({from: 'orangehrmlive.com'}, '_tracker/orange') +
178 label_archive({from: 'concursolutions.com'}, '_tracker/concur') +
179 label_archive({from: 'errata@redhat.com'}, '_tracker/errata') +
180 label_archive({from: 'builds@travis-ci.com'}, '_build/travis') +
181 #label_archive({from: 'cvp-ops@redhat.com'}, '_build/cvp') +
182 label_archive({from: 'buildsys@redhat.com'}, '_build/buildsys') +
183 label_archive({from: 'meet-recordings-noreply@google.com'}, '_recordings') +
184 rh_mailing_list('bugzilla', '_tracker/bz') +
185 [
186 {
187 filter: {
188 query: "list:(*.github.com)"
189 },
190 actions: {
191 archive: true,
192 markRead: true,
193 labels: [
194 "area/github"
195 ]
196 }
197 },
198 {
199 filter: {
200 query: "list:(cvp-ops@redhat.com)"
201 },
202 actions: {
203 archive: true,
204 markRead: true,
205 markSpam: false,
206 labels: [
207 "_build/cvp"
208 ]
209 }
210 },
211 {
212 filter: {
213 from: "noreply+erratatool@redhat.com"
214 },
215 actions: {
216 archive: true,
217 markRead: true,
218 markSpam: false,
219 labels: [
220 "_tracker/errata"
221 ]
222 }
223 },
224 {
225 filter: {
226 from: "cpaas-ops@redhat.com"
227 },
228 actions: {
229 archive: true,
230 markRead: true,
231 markSpam: false,
232 labels: [
233 "_tracker/cpaas"
234 ]
235 }
236 },
237 {
238 filter: {
239 from: "noreply-cloud@google.com"
240 },
241 actions: {
242 labels: [
243 "cloud/google"
244 ]
245 }
246 },
247 {
248 filter: {
249 from: "customercare@ecompanystore.com"
250 },
251 actions: {
252 labels: [
253 "area/order"
254 ]
255 }
256 },
257 ],
258 labels: [
259 {
260 name: "area/admin",
261 color: {
262 background: "#98d7e4",
263 text: "#0d3b44"
264 }
265 },
266 {
267 name: "project/moby",
268 color: {
269 background: "#000000",
270 text: "#ffffff"
271 }
272 },
273 {
274 name: "area/ce"
275 },
276 {
277 name: "project/cdf"
278 },
279 {
280 name: "event/kubecon",
281 color: {
282 background: "#b99aff",
283 text: "#ffffff"
284 }
285 },
286 {
287 name: "status/waiting",
288 color: {
289 background: "#f2b2a8",
290 text: "#8a1c0a"
291 }
292 },
293 {
294 name: "area/interview",
295 color: {
296 background: "#000000",
297 text: "#ffffff"
298 }
299 },
300 {
301 name: "project/ocf",
302 color: {
303 background: "#b3efd3",
304 text: "#0b4f30"
305 }
306 },
307 {
308 name: "event/redhat-summit",
309 color: {
310 background: "#fb4c2f",
311 text: "#ffffff"
312 }
313 },
314 {
315 name: "area/training",
316 color: {
317 background: "#ffdeb5",
318 text: "#7a4706"
319 }
320 },
321 {
322 name: "project/docker",
323 color: {
324 background: "#b6cff5",
325 text: "#0d3472"
326 }
327 },
328 {
329 name: "area/learn",
330 color: {
331 background: "#e3d7ff",
332 text: "#3d188e"
333 }
334 },
335 {
336 name: "area/health"
337 },
338 {
339 name: "area/expense",
340 color: {
341 background: "#ffc8af",
342 text: "#7a2e0b"
343 }
344 },
345 {
346 name: "area/opensource",
347 color: {
348 background: "#b3efd3",
349 text: "#0b4f30"
350 }
351 },
352 {
353 name: "area/meetup"
354 },
355 {
356 name: "area/conference",
357 color: {
358 background: "#e3d7ff",
359 text: "#3d188e"
360 }
361 },
362 {
363 name: "area/travel",
364 color: {
365 background: "#fbe983",
366 text: "#594c05"
367 }
368 },
369 { name: "Notes" },
370 ] + lib.rulesLabels(self.rules),
371}