[Top][All Lists]

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

[elpa] externals/debbugs 7a12166 041/311: (debbugs-send-control-message)

From: Stefan Monnier
Subject: [elpa] externals/debbugs 7a12166 041/311: (debbugs-send-control-message): Allow reversing tags.
Date: Sun, 29 Nov 2020 18:41:36 -0500 (EST)

branch: externals/debbugs
commit 7a12166e9dd7522f7b00febab7c43e5aa594d9f4
Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
Commit: Lars Magne Ingebrigtsen <larsi@gnus.org>

    (debbugs-send-control-message): Allow reversing tags.
 ChangeLog      |  1 +
 debbugs-gnu.el | 14 ++++++++++----
 2 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 03303b3..aeafb5d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,7 @@
        * debbugs-gnu.el (debbugs-mode-map): Bind `q' to `bury-buffer',
        which seems more useful.
+       (debbugs-send-control-message): Allow reversing tags.
 2011-07-06  Stefan Monnier  <monnier@iro.umontreal.ca>
diff --git a/debbugs-gnu.el b/debbugs-gnu.el
index c7414be..0c50408 100644
--- a/debbugs-gnu.el
+++ b/debbugs-gnu.el
@@ -499,11 +499,14 @@ The following commands are available:
                          (cons new new))
-(defun debbugs-send-control-message (message)
+(defun debbugs-send-control-message (message &optional reverse)
   "Send a control message for the current bug report.
 You can set the severity or add a tag, or close the report.  If
 you use the special \"done\" MESSAGE, the report will be marked as
-fixed, and then closed."
+fixed, and then closed.
+If given a prefix, and given a tag to set, the tag will be
+removed instead."
    (list (completing-read
          "Control message: "
@@ -513,7 +516,8 @@ fixed, and then closed."
            "merge" "forcemerge"
            "owner" "noowner"
            "patch" "wontfix" "moreinfo" "unreproducible" "fixed" "notabug")
-         nil t)))
+         nil t)
+        current-prefix-arg))
   (let* ((id (or debbugs-bug-number    ; Set on group entry.
@@ -554,7 +558,9 @@ fixed, and then closed."
               ((member message '("important" "normal" "minor" "wishlist"))
                (format "severity %d %s\n" id message))
-               (format "tags %d %s\n" id message))))
+               (format "tags %d%s %s\n"
+                       id (if reverse " -" "")
+                       message))))
       (funcall send-mail-function))))
 (provide 'debbugs-gnu)

reply via email to

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