summaryrefslogtreecommitdiff
path: root/scripts/mumi.in
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2020-04-07 16:11:17 +0200
committerRicardo Wurmus <rekado@elephly.net>2020-04-07 16:11:17 +0200
commit3386525ffc93ee099f5c1ebe45a42a4e83339ff6 (patch)
treed88a7acb066dfe8f2a32db99b445440ec5f8ac12 /scripts/mumi.in
parent5c21d1deb3e534aedaaae4802423db0a5df041b0 (diff)
scripts: Add "fetch" command.
This is to fetch all emails, including archived ones.
Diffstat (limited to 'scripts/mumi.in')
-rw-r--r--scripts/mumi.in12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/mumi.in b/scripts/mumi.in
index a60cf15..2b1f70f 100644
--- a/scripts/mumi.in
+++ b/scripts/mumi.in
@@ -130,6 +130,18 @@
(if (and sender smtp)
(worker-loop opts)
(error "Both sender and smtp options must be provided!"))))
+ (("fetch")
+ (let ((nums (sort
+ (append-map (lambda (package)
+ (soap-invoke*
+ (%config 'debbugs)
+ get-bugs
+ `((package . ,package)
+ (archive . both))))
+ (%config 'packages)) >)))
+ (update-mboxes! nums)
+ (mu-index)
+ (update-bug-database! nums)))
(("worker")
(update-state!))
(("web" . rest)