[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] [debbugs] Add mu4e support.

From: Michael Albinus
Subject: Re: [PATCH] [debbugs] Add mu4e support.
Date: Fri, 28 Apr 2017 15:22:01 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

Ricardo Wurmus <address@hidden> writes:

> Hi,

Hi Ricardo,

> this patch is for the debbugs.el EPLA package.  It adds the mail client
> “mu4e” as a debbugs-gnu mail backend.
> When “debbugs-gnu-mail-backend” is set to “'mu4e”, visiting a bug will
> download the bug’s mbox file, turn it into a separate Maildir tree under
> “mu4e-maildir” called “emacs-debbugs.1234” where “1234” is the bug id,
> runs “mu index” (synchronously) to update the mail database, and then
> shows the emails as usual with mu4e.
> I’ve been using this patch for a while with satisfactory results.

I've played with this. First of all, I had to install mu from
the source tarball; I didn't find it as package. I've compiled it, there
were errors in compiling mu and warnings in compiling mu4e. Well, I
don't care too much; I don't want to use it myself.

After applying your patch to debbugs-gnu.el, there are further warnings:

--8<---------------cut here---------------start------------->8---
In toplevel form:
packages/debbugs/debbugs-gnu.el:1346:1:Warning: Unused lexical argument

In debbugs-read-emacs-bug-with-mu4e:
packages/debbugs/debbugs-gnu.el:1354:27:Warning: reference to free variable
packages/debbugs/debbugs-gnu.el:1366:13:Warning: assignment to free variable
packages/debbugs/debbugs-gnu.el:1369:15:Warning: assignment to free variable
packages/debbugs/debbugs-gnu.el:1374:57:Warning: reference to free variable
packages/debbugs/debbugs-gnu.el:1371:21:Warning: reference to free variable
--8<---------------cut here---------------end--------------->8---

And indeed, after setting debbugs-gnu-mail-backend to 'mu4e, I've got
the error

debbugs-gnu-select-report: Symbol’s value as variable is void: mu4e-maildir

So I've loaded mu4e.el. Now I get the error

debbugs-read-emacs-bug-with-mu4e: Wrong number of arguments: #[(&optional expr 
prompt edit ignore-history) "Ä

The rest of the backtrace cannot be added to this email due to non-ASCII

Some comments to your code:

> +(defun debbugs-read-emacs-bug-with-mu4e (id status merged)
> +  "Read email exchange for debbugs bug ID.
> +STATUS is the bug's status list.
> +MERGED is the list of bugs merged with this one."
> +  (let* ((bug-str (number-to-string id))
> +         (tmpdir  "/tmp")

Pls use temporary-file-directory.

> +         (mbox    (concat tmpdir "/bug-" bug-str ".mbox"))
> +         (subdir  (concat "/emacs-debbugs." bug-str))
> +         (maildir (concat mu4e-maildir subdir)))
> +    ;; Create temporary maildir structure
> +    (dolist (dir '("cur" "new" "tmp"))
> +      (make-directory (concat maildir "/" dir) t))

Please use expand-file-name where appropriate.

Could you, pls, try to fix these problems? And don't forget the
contribution to debbugs-ug.texi.

> Ricardo

Best regards, Michael.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]