From: John Hendy <jw.hendy@gmail.com>
To: David Talmage <david.talmage@shoutpoint.com>
Cc: emacs-orgmode <emacs-orgmode@gnu.org>
Subject: Re: Bug: org-mode interprets * as a headline in text between #+BEGIN_.. and #+END_...
Date: Thu, 6 Oct 2016 16:13:08 -0500 [thread overview]
Message-ID: <CA+M2ft8LQ1KohyQobkpNaLC+YJBFUC70e6Sewic9kvOzcGAGzA@mail.gmail.com> (raw)
In-Reply-To: <CAM6q_N6=MEBc=vOcO2w5E31Tx6M4gVwu7oAUukhEMFQASk4fXg@mail.gmail.com>
On Thu, Oct 6, 2016 at 3:28 PM, David Talmage
<david.talmage@shoutpoint.com> wrote:
> I often paste verbatim text into the lab notebook I keep with org-mode.
> Org-mode always interprets any line that begins with an asterisk as a
> headline, even when the line is surrounded by #+BEGIN_... and #+END_...
> patterns. This breaks org-special-edit, making it complain, "No special
> environment to edit here", unless I manually insert another character at the
> beginning of every line in the block that begins with an asterisk.
>
> The behavior surprised me. I found two ways to work around it. First, I
> can edit the would-be verbatim text as described above. It will always look
> like the original text in org-special-edit. That's marginally acceptable
> because it alters my original text and makes me take one more step before I
> can copy and paste it elsewhere. Second, I can put such text in a drawer.
> I discovered that org-mode does not mis-interpret my text in a drawer.
>
>
I don't have a good explanation of why, but I know you need a comma to
escape org syntax, even within src blocks:
- mention of it in the manual (footnote 4):
http://orgmode.org/manual/Literal-examples.html
- SO answer: http://stackoverflow.com/questions/7431167/escaping-org-mode-example-block-inside-of-an-example-block
> Here is an example. It's markdown text. I use #+{BEGIN,END}_EXAMPLE but
> this behavior occurs in all of the #+BEGIN_.. and #+END_... patterns.
>
> #+BEGIN_EXAMPLE
> This is the README.md for rfc-tools, a collection of programs for
> processing IETF RFCs.
>
> * fetch-rfcs-by-title.sh downloads into the current directory the RFCs
> whose titles contain the string given on the command line. Uses an
> rfc-index file in the current directory. Prefers the PDF version of
> RFCs but will obtain the text version if the PDF is not available.
>
> * fetch-sip-rfcs.sh downloads RFCs that contain "Session Initiation"
> in their titles into the current directory.
>
> * search-rfc-index.sh searches an rfc-index file in the current
> directory for the string given on the command line. The string can
> contain spaces.
>
> * join-titles.awk turns the contents of an rfc-index file into a
> series of long lines. Each line begins with the RFC number, then a
> space, then the rest of the entry from the rfc-index.
> #+END_EXAMPLE
>
next prev parent reply other threads:[~2016-10-06 21:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-06 20:28 Bug: org-mode interprets * as a headline in text between #+BEGIN_.. and #+END_ David Talmage
2016-10-06 21:13 ` John Hendy [this message]
2016-10-06 22:05 ` Nick Dokos
2016-10-07 6:09 ` Nicolas Goaziou
2016-10-07 13:55 ` David Talmage
2016-10-07 22:20 ` Nicolas Goaziou
2016-10-07 15:36 ` Nick Dokos
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=CA+M2ft8LQ1KohyQobkpNaLC+YJBFUC70e6Sewic9kvOzcGAGzA@mail.gmail.com \
--to=jw.hendy@gmail.com \
--cc=david.talmage@shoutpoint.com \
--cc=emacs-orgmode@gnu.org \
/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).