I cannot seem to set #+PROPERTY: header-args:R
as the first value and have it work the way I expect it to. This is used as an example for org-mode here.
Setting a language specific property for :exports
works. (I've put in some emacs-lisp
source blocks, and those results do not get shown.
Providing a name for the session does not change the output (i.e. :session *R*
)
Changing the order just makes the first one not work.
(As an aside, how can I check what a #+PROPERTY
is set to?)
org-mode 8.3.3 from elpa package. emacs-version 24.5.1 on OSX.
Some minimally working examples follow.
This works:
#+PROPERTY: header-args :session
#+PROPERTY: header-args:R :exports both
#+BEGIN_SRC R
x = 3
#+END_SRC
#+BEGIN_SRC R
x
#+END_SRC
resulting in:
x = 3
3
x
3
Also this works
#+PROPERTY: header-args :exports both
#+PROPERTY: header-args:R :session
#+BEGIN_SRC R
x = 3
#+END_SRC
#+BEGIN_SRC R
x
#+END_SRC
and results in the same results as above.
This does not work:
#+PROPERTY: header-args:R :session
#+PROPERTY: header-args:R :exports both
#+BEGIN_SRC R
x = 3
#+END_SRC
#+BEGIN_SRC R
x
#+END_SRC
resulting in:
x = 3
3
x
Also does not work
#+PROPERTY: header-args:R :exports both
#+PROPERTY: header-args:R :session
#+BEGIN_SRC R
x = 3
#+END_SRC
#+BEGIN_SRC R
x
#+END_SRC
resulting in:
x = 3
x
C-c C-c
with point at the#+PROPERTY
line? Sometimes if you are experiencing unexpected behaviour with properties, they simply haven't been refreshed and are not taking effect. See this answer: emacs.stackexchange.com/a/19363/8430#+PROPERTY
's have been in effect. @Tobias has the right answer for me below.