From mboxrd@z Thu Jan 1 00:00:00 1970 From: Achim Gratz Subject: Re: #+INCLUDE: myfile.html html does not include /literally/; Org processes Date: Sun, 01 Jun 2014 11:26:51 +0200 Message-ID: <87wqd1yo84.fsf@Rainer.invalid> References: <538AA6B8.40604@gmail.com> <8761kl12w9.fsf@Rainer.invalid> <87bnudf2u4.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60392) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wr22p-00020U-PE for emacs-orgmode@gnu.org; Sun, 01 Jun 2014 05:27:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wr22j-000677-Dw for emacs-orgmode@gnu.org; Sun, 01 Jun 2014 05:27:11 -0400 Received: from plane.gmane.org ([80.91.229.3]:60124) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wr22j-000671-6j for emacs-orgmode@gnu.org; Sun, 01 Jun 2014 05:27:05 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1Wr22i-0002Ze-7n for emacs-orgmode@gnu.org; Sun, 01 Jun 2014 11:27:04 +0200 Received: from pd9eb1409.dip0.t-ipconnect.de ([217.235.20.9]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 01 Jun 2014 11:27:04 +0200 Received: from Stromeko by pd9eb1409.dip0.t-ipconnect.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 01 Jun 2014 11:27:04 +0200 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 Nicolas Goaziou writes: > Thanks for the patch. However, I'd rather not allow arbitrary blocks > around included files, as it can be the source of some headache (e.g., > a quote block around an Org file containing a headline). Also we don't > really need it since most use-cases are already supported. Fair enough. FWIW, I'm pretty sure the problem of the OP can also be solved with Babel, perhaps even with an inline function, but I haven't yet tried and it's likely to be quite a bit less intuitive than using INCLUDE. > Actually, I think there are two possible ways to handle this: > > 1. Add a new "export" (or something else) parameter which will wrap > file contents within an export block relative to the current > back-end. Unfortunately, this will not work for exotic back-ends > that do not provide such a block (:export-block property in its > definition). We can always fallback to an example block in this > case, though. Please not. > 2. Extend "src" syntax to allow Babel parameters after the language. > E.g., > > #+INCLUDE: "file.html" src html :results html That looks better, but still isn't quite self-explanatory. What happens if I write #+INCLUDE: "file.html" src html :results elisp for instance? That would still wrap the include file with an almost arbitrary block, no? I don't think you can check that the file to be included fulfills all the requirements of being included at that point anyway. Here are two more options with different degrees of iffyness: #+INCLUDE_HTML: "file.html" #+BEGIN_HTML <<"file.html">> #+END_HTML Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Factory and User Sound Singles for Waldorf Q+, Q and microQ: http://Synth.Stromeko.net/Downloads.html#WaldorfSounds