It is possible to define a macro in an org
file as follow:
#+MACRO: macroname
Is it possi
There is another solution which seems to work correctly. From org-macro.el source code:
;; VALUE starts with "(eval": it is a s-exp, `eval' it.
(when (string-match "\\`(eval\\>" value)
(setq value (eval (read value))))
Thus, you may define macro like this:
#+MACRO: newline (eval "\n")
Substitutions are also supported. The macro
#+MACRO: img (eval "#+CAPTION: $1\nfile:$2")
which is called as
{{{img(hello world!, ./img1.jpg)}}}
will be replaced with:
#+CAPTION: hello world!
file:./img1.jpg