From: Richard Lawrence <richard.lawrence@berkeley.edu>
To: "Fraga, Eric" <e.fraga@ucl.ac.uk>, Samuel Wales <samologist@gmail.com>
Cc: "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: included text
Date: Mon, 04 Nov 2019 23:16:27 +0100 [thread overview]
Message-ID: <87wocfz3r8.fsf@aquinas> (raw)
In-Reply-To: <xuu6imo0kp7m.fsf@ucl.ac.uk>
"Fraga, Eric" <e.fraga@ucl.ac.uk> writes:
> Mind you, an alternative could be #+CALL-ing a src block
> that generates the text as output?
On these lines: I've been thinking recently that it would be great to be
able to tangle/export other kinds of blocks (quotes, examples, etc.) via
the same kind of mechanism that src blocks use.
This would be really useful for me for making e.g. handouts from the
file that contains notes for a talk or a paper.
I've done this in the past with src blocks containing Org source code.
So instead of writing
#+begin_quote
Yada yada
#+end_quote
I write
#+begin_src org :tangle handout.org
,#+begin_quote
Yada yada
,#+end_quote
#+end_src
and create the handout.org file via org-babel-tangle.
This works but it is pretty clunky, and you lose a lot of the benefit of
having the original quote block. For one thing, it no longer exports as
a quote from the original file, but as source code. I'd rather just
write:
#+begin_quote :tangle handout.org
Yada yada
#+end_quote
or even better:
#+name: yada-quote
#+begin_quote
Yada yada
#+end_quote
and then in handout.org, something like:
#+include: talk.org::#yada-quote
Is there anyone who would be interested in this besides just me and
Samuel? (Can this already be done somehow in a non-clunky way?? I find
John's suggestion intriguing but too clunky: it seems like I shouldn't
have to pass a block of text through a shell or Python interpreter just
to include it verbatim in another Org file!)
--
Best,
Richard
next prev parent reply other threads:[~2019-11-04 22:16 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-02 22:50 included text Samuel Wales
2019-11-03 13:38 ` Fraga, Eric
2019-11-03 19:36 ` Samuel Wales
2019-11-03 19:37 ` Samuel Wales
2019-11-04 8:42 ` Fraga, Eric
2019-11-04 12:40 ` John Kitchin
2019-11-04 22:16 ` Richard Lawrence [this message]
2019-11-05 0:25 ` Samuel Wales
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87wocfz3r8.fsf@aquinas \
--to=richard.lawrence@berkeley.edu \
--cc=e.fraga@ucl.ac.uk \
--cc=emacs-orgmode@gnu.org \
--cc=samologist@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).