Skip to main content
11 events
when toggle format what by license comment
Dec 29, 2014 at 6:43 history edited wvxvw CC BY-SA 3.0
added 2 characters in body
Dec 29, 2014 at 6:26 history edited wvxvw CC BY-SA 3.0
added 921 characters in body
Dec 29, 2014 at 6:19 comment added wvxvw @h4labs OK, probably some explanation is due here. If a code block states :exports none, this means it will not be exported, i.e. you would need to evaluate it manually (although, only once per Emacs session in this case). Second assumption I've made here is that you would call (org-babel-do-load-languages 'org-babel-load-languages '((html . t))) (but you would certainly want it to have more languages listed). I'll add this to the answer as well.
Dec 29, 2014 at 4:55 comment added h4labs This didn't actually work for me. I didn't get any html output. I even try something simpler like <hr>
Dec 23, 2014 at 22:24 comment added Malabarba I see. It makes sense now.
Dec 23, 2014 at 22:13 comment added wvxvw @Malabarba Yup, but to the best of my knowledge there isn't an ob-html.el. So to export a block of HTML one would have to define such a function (I do this for other markups I use, in particular for YAML). This is different from #+begin_html ... #+end_html in that I can also use this as a primitive template engine via passing variables to the blocks (my actual org-babel-execute:html is more involved than that).
Dec 23, 2014 at 21:38 comment added Malabarba I don't know, I just assumed it did. What is the purpose of the first code block? Doesn't it define a function that changes how the second code block is processes?
Dec 23, 2014 at 20:20 comment added wvxvw @Malabarba I didn't know it had one (did it?).
Dec 23, 2014 at 11:50 comment added Malabarba It will also redefine org-babel-execute:html for the rest of that emacs session.
Dec 23, 2014 at 8:29 history edited wvxvw CC BY-SA 3.0
deleted 196 characters in body
Dec 23, 2014 at 8:19 history answered wvxvw CC BY-SA 3.0