From mboxrd@z Thu Jan 1 00:00:00 1970 From: Omid Subject: Re: 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 Message-ID: <525E0408.9040304@gmail.com> References: <525DE996.2000408@gmail.com> <87li1u0vuu.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:53786) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VWHX1-0007Fu-Aa for emacs-orgmode@gnu.org; Tue, 15 Oct 2013 23:12:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VWHWs-0004KF-Rl for emacs-orgmode@gnu.org; Tue, 15 Oct 2013 23:12:19 -0400 Received: from mail-yh0-x22d.google.com ([2607:f8b0:4002:c01::22d]:42495) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VWHWs-0004K4-M8 for emacs-orgmode@gnu.org; Tue, 15 Oct 2013 23:12:10 -0400 Received: by mail-yh0-f45.google.com with SMTP id i57so42796yha.18 for ; Tue, 15 Oct 2013 20:12:10 -0700 (PDT) In-Reply-To: <87li1u0vuu.fsf@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org 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 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: > [...] > This exports correctly >

>
> >
ls
> 
>
> >
    >
  • This also exports correctly >
  • >
>
> >
ls
> 
>
> >
    >
  • This does NOT export correctly (code block is not detected) >

    > #+BEGIN_SRC sh >

    >
  • >
>

> ls >

>

> #+END_SRC >

> > with html export, the last case does look quite different from the other ones. >