emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Derek Feichtinger <derek.feichtinger@psi.ch>
To: emacs-orgmode@gnu.org
Subject: org-export-babel-evaluate=nil ignores ":exports results" setting - this has changed
Date: Mon, 20 Feb 2017 23:02:07 +0100	[thread overview]
Message-ID: <38f5c7e0-b000-f8bd-97dd-6947e3272511@psi.ch> (raw)

When org-export-babel-evaluate is set to nil, I see a different behavior 
now as compared to earlier versions of org.

Now it seems that all header arguments of a code block are ignored, 
including the arguments to the :exports setting. Even when I have set 
":exports results" or ":exports code" I always get code and results 
exported in the resulting document. If org-export-babel-evaluate is set 
to t then everything behaves the way I was used to, ":exports results" 
just exports the results and when set to "code" just the code is exported.

I think that this should be considered a bug. I frequently (even most of 
the time) want to evaluate the org blocks manually, not upon export, but 
I want to be able to define whether only the results should be visible 
in the exported document. For generated pictures this is usually the 
normal case.

I am using org 9.0.5 from MELPA now, and I can't completely say when 
this changed, but I am very sure that a few weeks ago the behavior was 
different, since I am using org a lot for preparing documents.

Simple test document:

#####################
* Test

   #+BEGIN_SRC elisp :results output :exports code
     (princ (format "This should only export the code\nemacs %s\norg %s" 
emacs-version org-version))
   #+END_SRC

   #+RESULTS:
   : This should only export the code
   : emacs 25.1.1
   : org 9.0.5

   #+BEGIN_SRC elisp :results output :exports results
     (princ (format "This should only export the results\nemacs %s\norg 
%s" emacs-version org-version))
   #+END_SRC

   #+RESULTS:
   : This should only export the results
   : emacs 25.1.1
   : org 9.0.5


* COMMENT Org babel settings
Local Variables:
org-export-babel-evaluate: nil
End:

####################
ASCII exported document when org-export-babel-evaluate: nil


1 Test
======

   ,----
   | (princ (format "This should only export the code\nemacs %s\norg %s" 
emacs-version org-version))
   `----

   ,----
   | This should only export the code
   | emacs 25.1.1
   | org 9.0.5
   `----

   ,----
   | (princ (format "This should only export the results\nemacs %s\norg 
%s" emacs-version org-version))
   `----

   ,----
   | This should only export the results
   | emacs 25.1.1
   | org 9.0.5
   `----

####################
ASCII exported document when org-export-babel-evaluate: t

1 Test
======

   ,----
   | (princ (format "This should only export the code\nemacs %s\norg %s" 
emacs-version org-version))
   `----

   ,----
   | This should only export the results
   | emacs 25.1.1
   | org 9.0.5
   `----


Best regards,
Derek


-- 
Paul Scherrer Institut
Dr. Derek Feichtinger                   Phone:   +41 56 310 47 33
Section Head Science-IT                 Email: derek.feichtinger@psi.ch
Building/Room No. WHGA/U126
CH-5232 Villigen PSI

             reply	other threads:[~2017-02-20 22:02 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-20 22:02 Derek Feichtinger [this message]
2017-02-20 23:54 ` org-export-babel-evaluate=nil ignores ":exports results" setting - this has changed Charles C. Berry
2017-02-21  6:05   ` Derek Feichtinger
2017-02-21 16:37     ` Charles C. Berry
2017-02-22 15:27       ` Colin Baxter
2017-02-22 15:45         ` Derek Feichtinger
2017-02-22 18:56           ` Colin Baxter
2017-02-21 10:51   ` Aaron Ecay
2017-02-21 16:40     ` Charles C. Berry

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=38f5c7e0-b000-f8bd-97dd-6947e3272511@psi.ch \
    --to=derek.feichtinger@psi.ch \
    --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).