emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] elpa-admin 1ee6e0e: * elpa-admin.el (elpaa--get-section): Use the


From: Stefan Monnier
Subject: [elpa] elpa-admin 1ee6e0e: * elpa-admin.el (elpaa--get-section): Use the whole section
Date: Sun, 20 Dec 2020 23:33:14 -0500 (EST)

branch: elpa-admin
commit 1ee6e0eea70b077631552a5b7953a60964149b7a
Author: Stefan Monnier <monnier@iro.umontreal.ca>
Commit: Stefan Monnier <monnier@iro.umontreal.ca>

    * elpa-admin.el (elpaa--get-section): Use the whole section
---
 elpa-admin.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/elpa-admin.el b/elpa-admin.el
index c546329..cec5298 100644
--- a/elpa-admin.el
+++ b/elpa-admin.el
@@ -818,9 +818,13 @@ Rename DIR/ to PKG-VERS/, and return the descriptor."
       (emacs-lisp-mode)       ;lm-section-start needs the outline-mode setting.
       (let ((start (lm-section-start hsection)))
         (when start
+          ;; FIXME: Emacs<28 had a bug in `lm-section-end', so cook up
+          ;; our own ad-hoc replacement.
+          (goto-char start) (forward-line 1)
+          (re-search-forward "^\\(;;;[^;\n]\\|[^; \n]\\)" nil t)
           (insert
            (prog1
-               (buffer-substring start (lm-section-end hsection))
+               (buffer-substring start (match-beginning 0))
              (erase-buffer)))
           (emacs-lisp-mode)
           (goto-char (point-min))



reply via email to

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