Benjamin McMillan <[email protected]> writes:

> I see. I don't follow the reasoning, but I'm happy to leave it as is. I do
> want
> to point out, in case the issue is revisited in the future, that
> `org-archive-to-archive-sibling' does explicitly fold the archive tree at
> the
> end, and so does end with the entire archived-to tree folded.

Fair point. So, the behavior is inconsistent between different kinds of
archiving. Then, I am not opposed to changes, as long as we make sure
that we end up with the same (possibly customizeable) folding state
after archiving. This is minor though.

> I attach a patch that simply uses a call to `org-with-wide-buffer' to
> preserve
> the narrowing state, and deletes the call to `org-fold-show-all'. It leaves
> the
> archived subtree dangling, but this doesn't bother me personally, because I
> don't see it when narrowed to some other subtree.

Thanks!
Applied, onto main, after changing the commit to be more descriptive.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=7174dac7f
Fixed.

-- 
Ihor Radchenko // yantar92,
Org mode maintainer,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to