emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Vikas Rawal <vikaslists@agrarianresearch.org>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: org-mode mailing list <emacs-orgmode@gnu.org>
Subject: Re: "header-args :eval inline-only" not working
Date: Sun, 20 Aug 2017 02:06:58 +0530	[thread overview]
Message-ID: <672780F6-F156-4D48-8774-3E449FF4EA5B@agrarianresearch.org> (raw)
In-Reply-To: <87fucnjr3h.fsf@nicolasgoaziou.fr>

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


> On 20-Aug-2017, at 12:57 AM, Nicolas Goaziou <mail@nicolasgoaziou.fr> wrote:
> 
> Hello,
> 
> Vikas Rawal <vikaslists@agrarianresearch.org> writes:
> 
>> My org-version (latest on org ELPA) is: Org mode version 9.0.9 (9.0.9-82-gb862c2-elpa @ /Users/vikas/.emacs.d/elpa/org-20170814/)
>> 
>> The following is not working: 
>> 
>> #+PROPERTY: header-args :eval inline-only
>> 
>> ":eval never-export” works; but ":eval inline-only" does not.
> 
> What is "not working”?

":eval inline-only" has no effect. It still tries to evaluate all code blocks.


>> I can deal with this by globally changing the option using:
>> 
>> (org-export-babel-evaluate (quote inline-only))
>> 
>> But this creates another problem. After this, org does not respect “:exports results” and exports both the code and results.
> 
> Could you provide an ECM?

Please see the attached file.

When I export this, it still tries to evaluate the code block ind1_t2_hhd_code. If I use (org-export-babel-evaluate (quote inline-only)), it does not evaluate  ind1_t2_hhd_code code block but it exports both the code and the output.

Vikas


[-- Attachment #2: testecm.org --]
[-- Type: application/octet-stream, Size: 2063 bytes --]

#+Title: ECM to decifer problem with eval
#+AUTHOR: 
#+LATEX_HEADER: \usepackage{longtable,threeparttable,booktabs}
#+OPTIONS: toc:nil H:2 ^:{}
#+LATEX_CLASS_OPTIONS: [11pt,a4paper]
#+LATEX_HEADER: \linespread{1.5}
#+LATEX_HEADER: \usepackage{tabulary,tcolorbox,xcolor,tabularx,siunitx,booktabs}
#+LATEX_HEADER: \usepackage[margin=1in]{geometry}
#+LATEX_HEADER: \usepackage[section]{placeins}
#+LATEX_HEADER: \usepackage{dblfloatfix}
#+LATEX_HEADER: \usepackage{chngcntr}
#+LATEX_HEADER: \usepackage{multicol,vwcol,lipsum}
#+LATEX_HEADER: \counterwithin{table}{section}
#+PROPERTY: header-args :session nss70 :eval inline-only
#+macro: getcell src_emacs-lisp[:results value raw]{(org-table-get-remote-range "$1" "$2")}
#+macro: roundnum src_emacs-lisp[:results value raw]{(round (string-to-number (org-table-get-remote-range "$1" "$2")))}

* Overall trends


Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque vel arcu vitae velit finibus dictum. Aliquam blandit maximus ex, eget bibendum lectus sodales nec. Mauris vitae arcu cursus velit aliquam luctus. Vivamus sed dui feugiat, mattis libero at, vulputate eros. Duis eu velit mi. Sed sit amet scelerisque erat. Aliquam nulla metus, laoreet a metus vel, fermentum tempus odio. Phasellus sagittis vulputate est, in bibendum felis lacinia interdum. Aliquam dictum mauris ut commodo elementum. Maecenas scelerisque, lectus ut sagittis gravida, elit enim rutrum felis, eget cursus mi quam eget odio. Aliquam congue neque non arcu aliquam semper. Nunc eu congue lorem. Praesent dolor risus, porta convallis tempus et, mattis eget nunc {{{getcell(ind1_t2_hhd,@3$2)}}} per cent in 2002 to {{{get
 cell(ind1_t2_hhd,@4$2)}}} per cent in 2012.

#+NAME: ind1_t2_hhd_code
#+BEGIN_SRC R :results value :exports results :colnames yes :hline yes
data.frame(a=c(1:4),b=c(5:8))

#+END_SRC

#+NAME: ind1_t2_hhd
#+CAPTION: Caption of my table
#+attr_latex: :environment tabulary :width \columnwidth :align lRRR :booktabs t
#+RESULTS: ind1_t2_hhd_code
| a | b |
|---+---|
| 1 | 5 |
| 2 | 6 |
| 3 | 7 |
| 4 | 8 |

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




  reply	other threads:[~2017-08-19 20:37 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-19 16:36 "header-args :eval inline-only" not working Vikas Rawal
2017-08-19 19:27 ` Nicolas Goaziou
2017-08-19 20:36   ` Vikas Rawal [this message]
2017-08-19 22:10     ` Berry, Charles
2017-08-20  1:10       ` Vikas Rawal
2017-08-20  2:07         ` Berry, Charles
2017-08-20  2:24           ` Vikas Rawal
2017-08-20  2:43             ` Berry, Charles
2017-08-20  3:26               ` Vikas Rawal
2017-08-20 10:21                 ` Nicolas Goaziou
2017-08-20 12:41                   ` Vikas Rawal
2017-08-20 16:51                   ` Berry, Charles
2017-08-26  8:34                     ` Nicolas Goaziou

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=672780F6-F156-4D48-8774-3E449FF4EA5B@agrarianresearch.org \
    --to=vikaslists@agrarianresearch.org \
    --cc=emacs-orgmode@gnu.org \
    --cc=mail@nicolasgoaziou.fr \
    /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).