[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Org mode export to HTML not working correctly with code blocks i
From: |
Omid |
Subject: |
Re: [O] Org mode export to HTML not working correctly with code blocks if block is after an item (-) and its delimiters are indented |
Date: |
Tue, 15 Oct 2013 23:12:08 -0400 |
User-agent: |
Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.0 |
Thank you for your quick reply, Thorsten.
Yes, as I mentioned, and as you noticed, the HTML export does not seem
to work correctly for the last case. The #BEGIN_SRC and #END_SRC
delimiters are exported literally.
--
Omid
Sent from my Emacs
On 10/15/2013 10:53 PM, Thorsten Jolitz wrote:
>
> PS:
>
> Omid <address@hidden> writes:
>
>> When exporting to HTML (Org mode version 8.2.1 ELPA; GNU Emacs version
>> 24.3.1) I see the a strange behavior which can be reproduced with the
>> following minimal example:
>>
>> This exports correctly
>> #+BEGIN_SRC sh
>> ls
>> #+END_SRC
>>
>> - This also exports correctly
>> #+BEGIN_SRC sh
>> ls
>> #+END_SRC
>>
>> - This does NOT export correctly (code block is not detected)
>> #+BEGIN_SRC sh
>> ls
>> #+END_SRC
>>
>> Is there any way around this behavior without removing the indentation
>> for the code block delimiters?
>
> This exports correctly
> #+BEGIN_SRC sh
> ls
> #+END_SRC
>
> - This also exports correctly
> #+BEGIN_SRC sh
> ls
> #+END_SRC
>
> - This does NOT export correctly (code block is not detected)
> #+BEGIN_SRC sh
> ls
> #+END_SRC
>
>
> #+begin_src emacs-lisp :exports value
> (with-current-buffer
> (current-buffer)
> (org-export-as 'html))
> #+end_src
>
> #+results:
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
> [...]
> This exports correctly
> </p>
> <div class="org-src-container">
>
> <pre class="src src-sh">ls
> </pre>
> </div>
>
> <ul class="org-ul">
> <li>This also exports correctly
> </li>
> </ul>
> <div class="org-src-container">
>
> <pre class="src src-sh">ls
> </pre>
> </div>
>
> <ul class="org-ul">
> <li>This does NOT export correctly (code block is not detected)
> <p>
> #+BEGIN_SRC sh
> </p>
> </li>
> </ul>
> <p>
> ls
> </p>
> <p>
> #+END_SRC
> </p>
>
> with html export, the last case does look quite different from the other ones.
>