Package: dpkg-dev-el
Version: 26.11-1
Severity: wishlist
Tags: patch

Hello,

digging into the code I found that `debian-changelog-close-bug' offers
an open-bug list completion, which seems not to be documented at all
[1].  In my case, most of the time `debian-bug-open-alist' is empty,
because it's not auto-generated [2] and because to generate it you
need to access the "Bugs" menu, choose to generate the menu and then
finally choose to generate the list.  Ehm, I've `(menu-bar-mode -1)'
in my .emacs [3].

The attached patch adds a new mode keybinding to generate
`debian-bug-open-alist':

--8<---------------cut here---------------start------------->8---
--- debian-changelog-mode.el.ORG        2007-05-15 00:03:11.000000000 +0100
+++ debian-changelog-mode.el    2007-06-25 10:36:06.000000000 +0100
@@ -576,6 +576,8 @@
   (setq debian-changelog-mode-map (make-sparse-keymap))
   (define-key debian-changelog-mode-map "\C-c\C-a"
     'debian-changelog-add-entry)
+  (define-key debian-changelog-mode-map "\C-c\C-o"
+    'debian-changelog-build-open-bug-list)
   (define-key debian-changelog-mode-map "\C-c\C-b"
     'debian-changelog-close-bug)
   (define-key debian-changelog-mode-map "\C-c\C-f"
@@ -613,6 +615,7 @@
    ["New Version" debian-changelog-add-version (debian-changelog-finalised-p)]
    ["Add Entry" debian-changelog-add-entry
     (not (debian-changelog-finalised-p))]
+   ["Build Open Bug List" debian-changelog-build-open-bug-list]
    ["Close Bug" debian-changelog-close-bug
     (not (debian-changelog-finalised-p))]
    "--"
@@ -663,6 +666,7 @@
    ["New Version" debian-changelog-add-version (debian-changelog-finalised-p)]
    ["Add Entry" debian-changelog-add-entry
     (not (debian-changelog-finalised-p))]
+   ["Build Open Bug List" debian-changelog-build-open-bug-list]
    ["Close Bug" debian-changelog-close-bug
     (not (debian-changelog-finalised-p))]
    "--"
@@ -779,6 +783,11 @@
 (defvar debian-changelog-close-bug-takes-arg t
   "A compatibility flag for debian-bug.el.")
 
+(defun debian-changelog-build-open-bug-list ()
+  "Generate open bugs list, i.e. `debian-bug-open-alist'."
+  (interactive)
+  (debian-bug-build-bug-menu (debian-changelog-suggest-package-name)))
+
 (defun debian-changelog-close-bug (bug-number)
   "Add a new change entry to close a BUG-NUMBER."
   (interactive
--8<---------------cut here---------------end--------------->8---

Please consider for inclusion, TIA.

Thx, bye,
Gismo / Luca

Footnotes: 
[1] except a small "hint" in the README.Debian
[2] which is perfectly fine and correct, as it requires a working
    Internet connection
[3] I could agree it's my fault, thus the severity is wishlist

-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (990, 'unstable'), (500, 'testing'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.21-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages dpkg-dev-el depends on:
ii  debian-el                   26.11-1      Emacs helpers specific to Debian u
ii  emacs-snapshot-gtk [emacsen 1:20070617-1 The GNU Emacs editor (with GTK+ 2.
ii  emacs-snapshot-nox [emacsen 1:20070617-1 The GNU Emacs editor (without X su

Versions of packages dpkg-dev-el recommends:
ii  wget                          1.10.2-3   retrieves files from the web

-- debconf-show failed

Attachment: pgpwf9MRtpRKk.pgp
Description: PGP signature

Reply via email to