From 49b1092d7f82354390304dcc40e72cea73618956 Mon Sep 17 00:00:00 2001 Message-Id: <49b1092d7f82354390304dcc40e72cea73618956.1658892670.git.yantar92@gmail.com> From: Ihor Radchenko Date: Wed, 27 Jul 2022 11:30:19 +0800 Subject: [PATCH] * lisp/org.el (org-store-log-note): Do not indent empty lines in notes See https://orgmode.org/list/m235eo9d8b.fsf@ntnu.no --- lisp/org.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index ca0b12550..6817e44c1 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -10397,8 +10397,9 @@ (defun org-store-log-note () (let ((ind (org-list-item-body-column (line-beginning-position)))) (dolist (line lines) (insert-and-inherit "\n") - (indent-line-to ind) - (insert-and-inherit line))) + (unless (string-empty-p line) + (indent-line-to ind) + (insert-and-inherit line)))) (message "Note stored") (org-back-to-heading t)))))) ;; Don't add undo information when called from `org-agenda-todo'. -- 2.35.1