I used to make tree diagrams with dot in orgmode.
#+BEGIN_SRC dot :file hallo1_1_1.png
digraph hallo1_1_1 {
A [shape = "circle",style=filled, fillcolor=yellow]
}
#+END_SRC
Now, to pass latex commands (\def\mycommand{args})to my diagrams I would like to use dot2tex. (the usepackages are in ~/.emacs)
\\usepackage[utf8]{inputenc}
\\usepackage[T1]{fontenc}
\\usepackage{graphicx}
\\usepackage{longtable}
\\usepackage{listings}
\\usepackage{xcolor}
\\usepackage{float}
\\usepackage{soul}
\\usepackage{amssymb}
\\usepackage{hyperref}
\\usepackage{sectsty}
\\usepackage{tabularx}
\\usepackage{pbox}
\\usepackage{tikz}
\\usepackage{stackengine}
\\usepackage{verbatim}
\\usepackage{changepage}
\\usepackage{dot2texi}
\\usepackage[pdf]{graphviz}
\\usetikzlibrary{shapes,arrows}
After using in my test.org:
#+headers: :cmdline latex -shell-escape
#+BEGIN_SRC latex
\digraph[scale=0.5]{MyGraph}{rankdir=LR; a->b; b->c}
#+END_SRC
I got the warning:
The file MyGraph.pdf hasn’t been created from MyGraph.dot yet.
Run ‘dot -Tpdf -o MyGraph.pdf MyGraph.dot’ to create it.
Or invoke LATEX with the -shell-escape option to have this done
automatically.
Is it possible to add the commandline arguments in the file correctly? I would like the commandline arguments in the file for workflow reasons. Thank you.