Customizing org-mode export template?
Related to this question: How to define template for org-mode HTML export?
I'd like to customize the template inserted by hitting C-c C-e t
such that I get a few customizations and even some help notes in some comments on what to put.
Maybe it would be better to use some other Emacs way to insert a text snippet? Or to use org-mode template expansion?
Short Answer: Does not look to be easily accomplished to modify the structure dramatically. There are some export-options suggested like org-export-plist-vars
but I personally have not played with them.
Digging for the Answer:
When you call C-c C-e t, you are invoking the org-mode function org-insert-export-options-template
. I did a quick help on the function (C-h f) and didn't see any helping text or options to pass to it, so I had to look at the source of the function (M-x find-function
ENTER org-insert-export-options-template
ENTER>).
Reading through the org-insert-export-options-template
function, I see that it is acquiring the text to insert via org-get-current-options
. No help on configuring it's behavior in it's description, so off to view it's source as well. There you will see the familiar full bodied paragraph of template information that is inserted into the text when you call org-insert-export-options-template
. The values populate are from various other org variables, buffer name, etc.
Recommendation: What I personally have done is spent some time deciding which options I'd like and copied those from other org files when I start a new one. I have also thought about using AutoInsertMode to auto-populate a new org file for me but have put it off.