From 590a518fb9284b443c146ccbcf9846b2160abbd2 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Sun, 6 Sep 2009 07:05:25 +0200 Subject: [PATCH] Fix order bug when cleaning up entry lines for agenda --- lisp/org-agenda.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index 2739e8ce4..7171cbb2a 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -2332,8 +2332,6 @@ This will ignore drawers etc, just get the text." (goto-char (point-min)) (while (re-search-forward kwd-time-re nil t) (replace-match "")) - (if (re-search-forward "[ \t\n]+\\'" nil t) - (replace-match "")) (goto-char (point-min)) (when org-agenda-entry-text-exclude-regexps (let ((re-list org-agenda-entry-text-exclude-regexps) re) @@ -2341,6 +2339,9 @@ This will ignore drawers etc, just get the text." (goto-char (point-min)) (while (re-search-forward re nil t) (replace-match ""))))) + (goto-char (point-max)) + (skip-chars-backward " \t\n") + (if (looking-at "[ \t\n]+\\'") (replace-match "")) ;; find and remove min common indentation (goto-char (point-min)) -- 2.11.4.GIT