From: drymer <drymer@autistici.org>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: lista de correo de org-mode <emacs-orgmode@gnu.org>
Subject: Re: Bug: org-export-as
Date: Wed, 8 Mar 2017 10:19:32 +0000 [thread overview]
Message-ID: <20170308101932.lc6k34o7ssllykk3@laptop> (raw)
In-Reply-To: <87bmtc3c21.fsf@nicolasgoaziou.fr>
[-- Attachment #1: Type: text/plain, Size: 5441 bytes --]
Hi,
Thanks for your time. Could you please retry and evaluate this:
,----
| (defun test-org-export ()
| (interactive)
| (save-excursion
| (org-mark-element)
| (forward-line) ;; donot export title
| (setq b (region-beginning))
| (setq e (region-end)))
| (message (org-export-as 'html t nil t)))
`----
And execute `M-x test-org-export RET' on the example header:
,---
| * TODO Testing :test:
| Nullam eu ante vel est convallis dignissim. Fusce suscipit, wisi nec
| facilisis facilisis, est dui fermentum leo, quis tempor ligula erat
| quis odio. Nunc porta vulputate tellus. Nunc rutrum turpis sed pede.
| Sed bibendum. Aliquam posuere. Nunc aliquet, augue nec adipiscing
| interdum, lacus tellus malesuada massa, quis varius mi purus non odio.
| Pellentesque condimentum, magna ut suscipit hendrerit, ipsum augue
| ornare nulla, non luctus diam neque sit amet urna. Curabitur
| vulputate vestibulum lorem. Fusce sagittis, libero non molestie
| mollis, magna orci ultrices dolor, at vulputate neque nulla lacinia
| eros. Sed id ligula quis est convallis tempor. Curabitur lacinia
| pulvinar nibh. Nam a sapien.
`---
And see if it happens? I see it clearly different when using different versions of emacs, and I know I'm not the only one[1]. On >emacs25 it does not execute `forward-line' for some reason and it includes the header.
If you still see the expected behaviour, what would you recommend me to do?
Regards
1 - https://github.com/redguardtoo/org2nikola/issues/5
On Wed, Mar 08, 2017 at 12:24:38AM +0100, Nicolas Goaziou wrote:
>Hello,
>
>drymer <drymer@autistici.org> writes:
>
>> I'm trying to debug the package org2nikola, which works on emacs-24.5
>> but not on >emacs-25. What I'm trying to see is why the title is
>> exported when using >emacs-25 but not when prior versions. For what I've
>> being testing, it doesn't seem related to the package but to org-mode or
>> emacs. I'll explain why I think this. An example text I want to export would be:
>>
>> ,---
>> | * TODO Testing :test:
>> | Nullam eu ante vel est convallis dignissim. Fusce suscipit, wisi nec
>> | facilisis facilisis, est dui fermentum leo, quis tempor ligula erat
>> | quis odio. Nunc porta vulputate tellus. Nunc rutrum turpis sed pede.
>> | Sed bibendum. Aliquam posuere. Nunc aliquet, augue nec adipiscing
>> | interdum, lacus tellus malesuada massa, quis varius mi purus non odio.
>> | Pellentesque condimentum, magna ut suscipit hendrerit, ipsum augue
>> | ornare nulla, non luctus diam neque sit amet urna. Curabitur
>> | vulputate vestibulum lorem. Fusce sagittis, libero non molestie
>> | mollis, magna orci ultrices dolor, at vulputate neque nulla lacinia
>> | eros. Sed id ligula quis est convallis tempor. Curabitur lacinia
>> | pulvinar nibh. Nam a sapien.
>> `---
>>
>> I would execute the function `org2nikola-export-subtree' in the
>> header. More or less, this function would guide us until the next
>> function with the above text, but not the header, marked as a region:
>>
>> ,----
>> | (org-export-as 'html t nil t)
>> `----
>>
>> In emacs-24.5 this function returns:
>>
>> ,----
>> | <p>
>> | Nullam eu ante vel est convallis dignissim. Fusce suscipit, wisi nec facilisis
>> | facilisis, est dui fermentum leo, quis tempor ligula erat quis odio. Nunc porta
>> | vulputate tell us. Nunc rutrum turpis sed pede. Sed bibendum. Aliquam posuere.
>> | Nunc aliquet, augue nec adipiscing interdum, lacus tellus malesuada massa, quis
>> | varius mi purus non odio. Pellentesque condimentum, magna ut suscipit hendrerit,
>> | ipsum augue ornare nulla, non luctus diam neque sit amet urna. Curabitur vulputate
>> | vestibulum lorem. Fusce sagittis, libero non molestie mollis, magna orci ultrices
>> | dolor, at vulputate neque nulla lacinia eros. Sed id ligula quis est convallis
>> | tempor. Curabitur lacinia pulvinar nibh. Nam a sapien.
>> | </p>
>> `----
>>
>> In >emacs-25 this function returns:
>>
>> ,----
>> | <div id="outline-container-org1ce23b7" class="outline-2">
>> | <h2 id="org1ce23b7">Testing</h2>
>> | <div class="outline-text-2" id="text-org1ce23b7">
>> | <p>
>> | Nullam eu ante vel est convallis dignissim. Fusce suscipit, wisi nec facilisis
>> | facilisis, est dui fermentum leo, quis tempor ligula erat quis odio. Nunc porta
>> | vulputate tellus. Nunc rutrum turpis sed pede. Sed bibendum. Aliquam posuere.
>> | Nunc aliquet, augue nec adipiscing interdum, lacus tellus malesuada massa, quis
>> | varius mi purus non odio. Pellentesque condimentum, magna ut suscipit hendrerit,
>> | ipsum augue ornare nulla, non luctus diam neque sit amet urna. Curabitur vulputate
>> | vestibulum lorem. Fusce sagittis, libero non molestie mollis, magna orci ultrices
>> | dolor, at vulputate neque nulla lacinia eros. Sed id ligula quis est convallis
>> | tempor. Curabitur lacinia pulvinar nibh. Nam a sapien.
>> | </p>
>> | </div>
>> | </div>
>> `----
>
>FWIW, I cannot reproduce it. When calling (org-export-as 'html t nil t)
>gets me the the first output. However, I get the latter when region
>includes the heading.
>
>Actually you cannot have both a region and subtree export. Pick the one
>you need.
>
>Regards,
>
>--
>Nicolas Goaziou
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2017-03-08 9:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-07 18:50 Bug: org-export-as drymer
2017-03-07 23:24 ` Nicolas Goaziou
2017-03-08 10:19 ` drymer [this message]
2017-03-08 10:58 ` Nicolas Goaziou
2017-03-08 12:43 ` drymer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170308101932.lc6k34o7ssllykk3@laptop \
--to=drymer@autistici.org \
--cc=emacs-orgmode@gnu.org \
--cc=mail@nicolasgoaziou.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).