summaryrefslogtreecommitdiff
path: root/lisp/textmodes
diff options
context:
space:
mode:
authorStefan Kangas <stefankangas@gmail.com>2022-09-16 16:06:09 +0200
committerStefan Kangas <stefankangas@gmail.com>2022-09-16 16:14:43 +0200
commitd407bdfd01a8fa4a1a20b8b0f1d07629be4ae54f (patch)
tree59c3009cf7b9f0cb347b27767e43bca76f63b48c /lisp/textmodes
parentec2dfd110c407038ab1abc7fd713d37ada91edd9 (diff)
downloademacs-d407bdfd01a8fa4a1a20b8b0f1d07629be4ae54f.tar.gz
Add command to delete temporary markers in NEWS
* lisp/textmodes/emacs-news-mode.el (emacs-news-delete-temporary-markers): New command. * admin/make-tarball.txt: Update instructions.
Diffstat (limited to 'lisp/textmodes')
-rw-r--r--lisp/textmodes/emacs-news-mode.el11
1 files changed, 11 insertions, 0 deletions
diff --git a/lisp/textmodes/emacs-news-mode.el b/lisp/textmodes/emacs-news-mode.el
index 6bf96deaccb..88e89480609 100644
--- a/lisp/textmodes/emacs-news-mode.el
+++ b/lisp/textmodes/emacs-news-mode.el
@@ -276,6 +276,17 @@ documentation marks on the previous line."
(forward-line -1))
(open-line n))
+(defun emacs-news-delete-temporary-markers ()
+ "Delete any temporary markers.
+This is used when preparing a new release of Emacs."
+ (interactive nil emacs-news-mode)
+ (goto-char (point-min))
+ (re-search-forward "^Temporary note:$")
+ (forward-line -1)
+ (delete-region (point) (save-excursion (forward-paragraph) (point)))
+ (while (re-search-forward (rx bol (or "+++" "---") eol) nil t)
+ (delete-line)))
+
(provide 'emacs-news-mode)
;;; emacs-news-mode.el ends here