-;;; debbugs-org.el --- Org-mode interface for the GNU bug tracker
+;;; debbugs-org.el --- Org-mode interface for the GNU bug tracker -*- lexical-binding:t -*-
;; Copyright (C) 2013-2016 Free Software Foundation, Inc.
(require 'debbugs-gnu)
(require 'org)
-(eval-when-compile (require 'cl))
+(eval-when-compile (require 'cl-lib))
;; Buffer-local variables.
(defvar debbugs-gnu-local-query)
(defconst debbugs-org-severity-priority
(let ((priority ?A))
(mapcar
- (lambda (x) (prog1 (cons x (char-to-string priority)) (incf priority)))
+ (lambda (x) (prog1 (cons x (char-to-string priority)) (cl-incf priority)))
debbugs-gnu-all-severities))
"Mapping of debbugs severities to TODO priorities.")
;; Do the search.
(debbugs-org severities packages))))
+;;;###autoload
+(defun debbugs-org-patches ()
+ "List the bug reports that have been marked as containing a patch."
+ (interactive)
+ (debbugs-org nil debbugs-gnu-default-packages nil nil "patch"))
+
;;;###autoload
(defun debbugs-org (severities &optional packages archivedp suppress tags)
"List all outstanding bugs."
;; Handle tags.
(when (string-match "^\\([0-9.]+\\); \\(.+\\)$" subject)
- (let ((x (match-string 1 subject))) (pushnew x tags :test #'equal))
+ (let ((x (match-string 1 subject))) (cl-pushnew x tags :test #'equal))
(setq subject (match-string 2 subject)))
(when archived
- (pushnew "ARCHIVE" tags :test #'equal))
+ (cl-pushnew "ARCHIVE" tags :test #'equal))
(setq tags
(mapcar
;; Replace all invalid TAG characters by "_".