all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Diego Zamboni <diego@zzamboni.org>
To: emacs-orgmode@gnu.org
Cc: Diego Zamboni <diego@zzamboni.org>
Subject: Specifying the tangle filename based on the source filename?
Date: Sun, 28 Jan 2018 14:54:44 +0100	[thread overview]
Message-ID: <BC7B8EF8-6790-4164-9AAA-070BCAF133C0@zzamboni.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 915 bytes --]

Hi,

I’ve been converting many of my configuration files to org-mode to better document them (examples: https://github.com/zzamboni/dot_emacs/blob/master/init.org <https://github.com/zzamboni/dot_emacs/blob/master/init.org>, https://github.com/zzamboni/dot_elvish/blob/master/rc.org <https://github.com/zzamboni/dot_elvish/blob/master/rc.org>). Usually I have a line like the following at the top of each org file:

#+PROPERTY: header-args:emacs-lisp :tangle init.el

So that all the code blocks in the file are, by default, tangled to the corresponding config file. I was wondering if it might be possible to avoid hardcoding the output file (“init.el” in this example) and instead derive it from the source filename (“init.org” in this case). I’ve looked a bit through the manual and although I found the {{{input-file}}} macro, I couldn’t get it to work.

Thanks for any help,
—Diego


[-- Attachment #2: Type: text/html, Size: 1472 bytes --]

             reply	other threads:[~2018-01-28 13:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-28 13:54 Diego Zamboni [this message]
2018-01-28 18:13 ` Specifying the tangle filename based on the source filename? Jack Henahan
2018-01-28 20:15   ` Diego Zamboni
2018-01-28 20:47 ` Grant Rettke
2018-01-28 21:07   ` Diego Zamboni

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=BC7B8EF8-6790-4164-9AAA-070BCAF133C0@zzamboni.org \
    --to=diego@zzamboni.org \
    --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.