From: Philip Hudson <phil.hudson@iname.com>
To: "Charles C. Berry" <ccberry@ucsd.edu>
Cc: emacs orgmode-mailinglist <emacs-orgmode@gnu.org>
Subject: Re: Tangling flow control
Date: Wed, 9 Nov 2016 22:59:23 +0000 [thread overview]
Message-ID: <CAJ1MqVGkE44AOaXT4cwmoxhYqet+2p_KqbtrK7fKcvUxrA6HEw@mail.gmail.com> (raw)
In-Reply-To: <alpine.OSX.2.20.1611091320590.1771@charles-berrys-macbook.local>
On 9 November 2016 at 21:41, Charles C. Berry <ccberry@ucsd.edu> wrote:
> The org src block is just a container. Its body is a src block template that
> gets copied into the variable `tmpl', which if filled and placed in file can
> be tangled.
That makes sense, but it seems to conflict with what you illustrate:
#+RESULTS:
#+BEGIN_src org
,#+BEGIN_SRC shell :tangle abc.sh
ls -lt my-dir
,#+END_SRC
#+END_src
I'd expect/want:
#+RESULTS:
#+BEGIN_SRC shell :tangle abc.sh
ls -lt my-dir
#+END_SRC
Wouldn't I?
> Alternatively, you can eval (setq tmpl "<template string>") somewhere (maybe
> in a local variables block), where the <template string> part is the
> template.
>
> But it seems easier to edit the template as an org src block - C-c ' puts
> your template in an OrgSrc buffer, then moving point to a src block and
> typing M-x org-edit-src-code puts its body in another OrgSrc buffer where
> you can edit it in the shell-mode or whatever mode.
>
> Also, I suppose that template should have been an ssh-config src block to
> conform with your earlier posting. But I think you get the idea.
Yes, that's no problem, I adapt it mutatis mutandum.
--
Phil Hudson http://hudson-it.ddns.net
Pretty Good Privacy (PGP) ID: 0x887DCA63
next prev parent reply other threads:[~2016-11-09 22:59 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-08 21:21 Tangling flow control Philip Hudson
2016-11-09 17:54 ` Charles C. Berry
2016-11-09 20:32 ` Philip Hudson
2016-11-09 21:41 ` Charles C. Berry
2016-11-09 22:59 ` Philip Hudson [this message]
2016-11-10 1:19 ` Charles C. Berry
2016-11-10 10:36 ` Philip Hudson
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAJ1MqVGkE44AOaXT4cwmoxhYqet+2p_KqbtrK7fKcvUxrA6HEw@mail.gmail.com \
--to=phil.hudson@iname.com \
--cc=ccberry@ucsd.edu \
--cc=emacs-orgmode@gnu.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.