> On Aug 19, 2017, at 1:36 PM, Vikas Rawal <vikasli...@agrarianresearch.org> > wrote: > > >> On 20-Aug-2017, at 12:57 AM, Nicolas Goaziou <m...@nicolasgoaziou.fr> wrote: >> >> Hello, >> >> Vikas Rawal <vikasli...@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.
Which contains: #+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")))} > > 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. > The first problem is that you have babel code *inside* a macro. Since macros are run after babel executes, nothing will happen. Next, there is no `:eval inline-only'. That seem to work only because only the negative cases are checked. i.e. it is the same as `:eval yes' or even `:eval yes-please-and-thank-you'. Instead of a macro containing babel, you can use `call_whatnot(a,b)' statements for inline execution, where a src block named `whatnot' handles the desired computations. You can execute these in advance of exporting and specify `:eval never-export'. HTH, Chuck p.s. I did not see a bug.