diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2020-04-22 10:21:59 +0200 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2020-04-22 10:30:00 +0200 |
commit | d3c08cb729461fd6e66065946251c60b223fa580 (patch) | |
tree | 29c40c6606b08b98aa2dde55b19cbf2eb77c0aaa | |
parent | 3aad292fe97fd512f088528b0c5ada2f6d4042d2 (diff) |
messages: Add bug-id->log-file.
-rw-r--r-- | mumi/messages.scm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/mumi/messages.scm b/mumi/messages.scm index b6b19a3..3d38c3e 100644 --- a/mumi/messages.scm +++ b/mumi/messages.scm @@ -42,6 +42,7 @@ bugs-by-severity update-mboxes! + bug-id->log-file multipart-message? extract-attachment)) @@ -155,6 +156,14 @@ we have to do this in a very convoluted way." (define (bug-id->mbox-file bug-id) (format #f "~a/mbox/~a" (%config 'mail-dir) bug-id)) +(define* (bug-id->log-file bug-id #:key archived?) + (format #f "~a/spool/~a/~a/~a.log" + (%config 'data-dir) + (if archived? "archive" "db-h") + (string-take-right (if (string? bug-id) + bug-id + (number->string bug-id)) 2) + bug-id)) ;; This is a modified version of fetch-mbox from guile-debbugs: it ;; supports downloading with an offset. It also doesn't bother with |