emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals-release/org 0616b3c375 2/3: org-export-as: Fix edge cas


From: ELPA Syncer
Subject: [elpa] externals-release/org 0616b3c375 2/3: org-export-as: Fix edge case during subtree export
Date: Sat, 10 Dec 2022 04:57:54 -0500 (EST)

branch: externals-release/org
commit 0616b3c375b03a04d3f4d7a479fe2a41ea8dc09f
Author: Ihor Radchenko <yantar92@posteo.net>
Commit: Ihor Radchenko <yantar92@posteo.net>

    org-export-as: Fix edge case during subtree export
    
    * lisp/ox.el (org-export-as): Make sure that narrowing includes top
    heading in a subtree when subtree export is requested.  This is needed
    after 927621910 changed `org-export--get-subtree-options' behavior.
    
    Reported-by: Alejandro PĂ©rez Carballo <apc@umass.edu>
    Link: https://orgmode.org/list/m2sfhpffui.fsf@umass.edu
---
 lisp/ox.el | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lisp/ox.el b/lisp/ox.el
index f6629cde4d..aed669ee87 100644
--- a/lisp/ox.el
+++ b/lisp/ox.el
@@ -3036,6 +3036,11 @@ Return code as a string."
               (org-narrow-to-subtree)
               (goto-char (point-min))
               (org-end-of-meta-data)
+               ;; Make the region include top heading in the subtree.
+               ;; This way, we will be able to retrieve its export
+               ;; options when calling
+               ;; `org-export--get-subtree-options'.
+               (backward-char)
               (narrow-to-region (point) (point-max))))
         ;; Initialize communication channel with original buffer
         ;; attributes, unavailable in its copy.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]