emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Eric Schulte <eric.schulte@gmx.com>
To: Frozenlock <frozenlock@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: [BUG] ORG-LIST-END-MARKER when exporting from within a babel block with an exclude or include tag
Date: Mon, 16 Jan 2012 08:18:53 -0700	[thread overview]
Message-ID: <87lip7smi5.fsf@gmx.com> (raw)
In-Reply-To: <CACjB3dt9ObrQYYa9Z5oO-NVZ3=n+wYGuawED=m0+wtpVos1EsQ@mail.gmail.com> (frozenlock@gmail.com's message of "Mon, 16 Jan 2012 00:01:19 -0500")

[-- Attachment #1: Type: text/plain, Size: 982 bytes --]

>
> If you export this file to PDF (C-c C-e d), babel will evaluate and
> export the file as ascii. However, the ascii file will have the
> undesirable "ORG-LIST-END-MARKER" in it.
> Here is the resulting ascii export:
>

Well, this certainly is an odd problem.  I can confirm that I recreated
the problem locally on export to .tex and .html, but not to .txt.  I had
to make the following changes to your example [1] before the code block
returned any results on export.

To make things stranger the marker does not appear in the results when
`org-export-blocks-preprocess' is run outside of a recursive export, or
when the code block is evaluated interactively.

I am not familiar enough with the list exporting code to know where to
begin looking into this, but since the buffer does return an elisp
string, one easy (though unclean) solution would be to
`replace-regexp-in-string' to manually strip the "ORG-LIST-END-MARKER"s
from the string.

Hope this helps,

Footnotes: 
[1]  

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: weird.org --]
[-- Type: text/x-org, Size: 448 bytes --]

#+TITLE: Test org file
#+EXPORT_INCLUDE_TAGS: test2

* First heading							      :test1:
Testing, 1-2, 1-2.

* Second heading						      :test2:
Because we can.

** Now a list
   - First item
   - Second item

#+BEGIN_SRC emacs-lisp :exports results :var buffer-file-name=(buffer-file-name)
(let ((org-export-babel-evaluate nil)); don't evaluate in 'recursive' exports
   (org-export-as-ascii org-export-headline-levels nil nil 'string))
#+END_SRC

[-- Attachment #3: Type: text/plain, Size: 48 bytes --]



-- 
Eric Schulte
http://cs.unm.edu/~eschulte/

      reply	other threads:[~2012-01-16 15:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-16  5:01 [BUG] ORG-LIST-END-MARKER when exporting from within a babel block with an exclude or include tag Frozenlock
2012-01-16 15:18 ` Eric Schulte [this message]

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=87lip7smi5.fsf@gmx.com \
    --to=eric.schulte@gmx.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=frozenlock@gmail.com \
    /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).