From 05804191279dffa716c73f148b1d7b9320d60139 Mon Sep 17 00:00:00 2001 From: Quentin Aristote Date: Fri, 19 Nov 2021 23:06:29 +0100 Subject: correct archive-all-read to not skip entries --- local/bibli-paris/bibli-paris.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'local') diff --git a/local/bibli-paris/bibli-paris.el b/local/bibli-paris/bibli-paris.el index 0822ec1..68955a7 100644 --- a/local/bibli-paris/bibli-paris.el +++ b/local/bibli-paris/bibli-paris.el @@ -399,7 +399,12 @@ STATE (string)." (interactive) (org-map-entries (lambda () (if (equal (org-get-todo-state) "DONE") - (org-archive-subtree))))) + (progn + ;; archiving an entry moves the cursor to next entry + ;; so we move it back to the previous entry + (org-archive-subtree) + (setq org-map-continue-from (outline-get-last-sibling)) + ))))) ;; minor mode -- cgit v1.2.3