From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: Re: org-html-h Date: Mon, 26 Jan 2015 21:50:09 +0100 Message-ID: <87y4op9shq.fsf@gmx.us> References: <54C6A566.2020607@m4x.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35813) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFqc8-0001iU-Tq for emacs-orgmode@gnu.org; Mon, 26 Jan 2015 15:50:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YFqc2-0002mt-NJ for emacs-orgmode@gnu.org; Mon, 26 Jan 2015 15:50:28 -0500 Received: from plane.gmane.org ([80.91.229.3]:36550) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFqc2-0002mP-G7 for emacs-orgmode@gnu.org; Mon, 26 Jan 2015 15:50:22 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1YFqbx-0000Bs-71 for emacs-orgmode@gnu.org; Mon, 26 Jan 2015 21:50:17 +0100 Received: from tsn109-201-154-147.dyn.nltelcom.net ([109.201.154.147]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 26 Jan 2015 21:50:17 +0100 Received: from rasmus by tsn109-201-154-147.dyn.nltelcom.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 26 Jan 2015 21:50:17 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hi Sébastien, Sébastien Brisard writes: > my blog (sbrisard.github.io) is entirely written with > org-mode. Looks pretty. > Org-mode offers everything I need, except for one minor > detail. It is very difficult to include the same CSS file in the > html-head of several files located at various levels of the directory > hierarchy. > I do not really like this trick > http://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.html#sec-6. For > the time being, I configured several projects (one for each level), > see https://github.com/sbrisard/blog/blob/master/sb-blog.el. But I am > not happy with this solution either. > I think that it would be great if org-html-head and > org-html-head-extra behaved as org-html-preamble and > org-html-postamble, which can be set to either a string, or a > function. This offers great flexibility for the configuration of the > pre/postamble (I use it to conditionnaly include DISQUS comments in > the postamble). > Would it be possible to mimick the same behavior with org-html-head > and org-html-head-extra? Or would this be too much work? You could use macros: #+MACRO: my-style (eval (concat "#+HTML_HEAD_EXTRA: " (if t "