summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2020-04-22 10:59:27 +0200
committerRicardo Wurmus <rekado@elephly.net>2020-04-22 10:59:27 +0200
commitcff8dde9a5ed82f1a3084ca7b3f1e22c4701a438 (patch)
tree53e4a690f3b25c39b4ab3e6e65d5868e0d606526
parenta5e068e3fb906d1e09e8581cc7d5016f78e4572c (diff)
mumi: Move bug-id->log-file to (mumi debbugs).
-rw-r--r--mumi/debbugs.scm13
-rw-r--r--mumi/messages.scm11
2 files changed, 12 insertions, 12 deletions
diff --git a/mumi/debbugs.scm b/mumi/debbugs.scm
index 405d020..c0f0c1c 100644
--- a/mumi/debbugs.scm
+++ b/mumi/debbugs.scm
@@ -16,12 +16,14 @@
;;; <http://www.gnu.org/licenses/>.
(define-module (mumi debbugs)
+ #:use-module (mumi config)
#:use-module (email email)
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (ice-9 match)
#:use-module (ice-9 rdelim)
- #:export (read-emails-from-bug-log))
+ #:export (read-emails-from-bug-log
+ bug-id->log-file))
(define* (read-emails-from-bug-log port
#:optional (keep '(incoming-recv)))
@@ -108,3 +110,12 @@ ends with ^C.
(if skip?
(loop mails lines type skip?)
(loop mails (cons line lines) type skip?))))))))
+
+(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))
diff --git a/mumi/messages.scm b/mumi/messages.scm
index f2f9868..edcaea4 100644
--- a/mumi/messages.scm
+++ b/mumi/messages.scm
@@ -42,8 +42,6 @@
wishlist-bugs
bugs-by-severity
- bug-id->log-file
-
multipart-message?
extract-attachment))
@@ -153,15 +151,6 @@ we have to do this in a very convoluted way."
(_ #f)))))))
-(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
;; msg-nums.