I get that there are different levels at which Header arguments in org mode, specifically LP can be defined and that the more specialized ones, i.e. deeper within the tree hierarchy, take precedence over the higher ones. So there are
- System-wide header arguments (usually in config files)
-File-wide header arguments
#+PROPERTY: header-args :dir "~/literate_test"
- Language-specific header arguments
- Header arguments in Org mode properties
:PROPERTIES:
:header-args: :results output :mkdirp yes
:header-args+: :var image_name=not_finished
:header-args+: :eval never-export
:header-args+:elisp: :exports code
:header-args+:dir: literate_test
:header-args+:tag: 'test'
:END:
- Language-specific header arguments in Org mode properties
- Code block specific header arguments
- Header arguments in function calls
and in order for arguments of the same kind to apply, I have to append them with +.
what confuses me though, is when do I have to use specific variables like below
* Header
:PROPERTIES:
:PRJ-DIR: ~/prj/dir/
:tangle: ~/dir/my/testfile.el
:END:
and when to use the :header-args: syntax
PROPERTIES:
:header-args: :results output :mkdirp yes
:END:
is there a rule to this?
Also, org seems to do some caching in the background when it comes to file local variables, header arguments etc. How does that work and how to refresh the entire buffer then?