[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bug: refiling gobbles a newline and absorbs the next heading [9.1.9
From: |
Miguel Morin |
Subject: |
Re: Bug: refiling gobbles a newline and absorbs the next heading [9.1.9 (release_9.1.9-65-g5e4542 @ /Applications/Emacs.app/Contents/Resources/lisp/org/)] |
Date: |
Tue, 11 Feb 2020 15:34:41 +0000 |
User-agent: |
mu4e 1.2.0; emacs 26.3 |
Hi Bastien,
Yes, it works! I appreciate your work, thank you very much.
I tested the code with the Org 9.3.3 and confirm that the first issue I
reported is fixed: now when I run `org-capture` and delete lines at the end of
the org-capture buffer I cannot delete the newline that in the org buffer
separates the capture item from the next heading.
The other issue I reported is still there, i.e. running this code:
```
(defun +org|insert-newlines ()
(beginning-of-buffer) (insert "\nhello world!\n")
(end-of-buffer) (insert "\nhello world!\n"))
+org|insert-newlines
(add-hook 'org-capture-before-finalize-hook #'+org|insert-newlines)
(+org|insert-newlines)
```
will insert "hello world!" at the beginning and end of the org buffer and not
the org-capture buffer. I'm not sure if this is intended, and I never use this
feature anyway. So I'm happy to close this matter here.
Miguel
On Wed, 05 Feb 2020 at 06:30 WET, Bastien wrote:
> Hi Miguel,
>
> I made a change in Org maint branch that could somehow impact the
> issue you reported. Can you test and see if it does?
>
> Morin <address@hidden> writes:
>
>> In the course of fixing this, I found another bug in using the hook
>> `org-capture-before-finalize-hook`, which adds text at the beginning
>> and end of the org buffer and not in the beggining and end of the
>> capture item.
>
> If this is really another bug, please fill a different bug report for
> it, it helps us track all issues separately.
>
> Thanks,