From: Eric Schulte <eric.schulte@gmx.com> To: avdi@avdi.org Cc: emacs-orgmode <emacs-orgmode@gnu.org> Subject: Re: Feature request for noweb mode that strips references on export Date: Wed, 01 Feb 2012 08:21:58 -0700 [thread overview] Message-ID: <87d39ylgt0.fsf@gmx.com> (raw) In-Reply-To: <CAPxgaC-Oj5aTTr6d_oxyATrJQ4JAcB2RmF0Z61+SQFmwOiL7_A@mail.gmail.com> Avdi Grimm <groups@inbox.avdi.org> writes: > Presently there are three noweb modes: yes, no, and tangle. I would > like a fourth, which would behave as follows: > > On tangle: normal noweb expansion is performed. > On evaluation: normal noweb expansion is performed. > On export: noweb references are STRIPPED. Not just ignored, but the > lines containing the references are removed before export. > > The use case is this: I find myself writing articles where I have a > series of code examples like this: > > #+begin_src ruby > <<boilerplate>> > 2 + 2 # => > #+end_src > > The boilerplate is required to make the sample work, but I don't want > to have the boilerplate code show up in the finished article, because > it would be repeated for every example. I also don't want the noweb > reference to show up in the finished article, because it will confuse > readers and syntax highlighters. > > Is this possible now, and/or a feature that could be easily added? > I've just added tested and documented such a "strip-export" argument to :noweb. Please let me know if it doesn't work as you expected. Best, > > Thanks, -- Eric Schulte http://cs.unm.edu/~eschulte/
next prev parent reply other threads:[~2012-02-01 15:23 UTC|newest] Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top 2012-01-31 4:11 Avdi Grimm 2012-01-31 7:56 ` Sebastien Vauban 2012-01-31 17:38 ` Avdi Grimm 2012-01-31 18:48 ` Avdi Grimm 2012-02-01 14:18 ` Eric Schulte 2012-02-01 15:21 ` Eric Schulte [this message] 2012-03-15 18:24 ` Avdi Grimm 2012-03-30 16:22 ` Sean O'Halpin 2012-03-30 16:37 ` Nick Dokos 2012-03-31 8:28 ` Sean O'Halpin 2012-03-30 16:39 ` Daimrod 2012-03-31 8:33 ` Sean O'Halpin 2012-03-31 9:04 ` Daimrod 2012-03-31 16:03 ` Nick Dokos 2012-03-31 15:32 ` Eric Schulte 2012-04-01 21:28 ` Sean O'Halpin
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=87d39ylgt0.fsf@gmx.com \ --to=eric.schulte@gmx.com \ --cc=avdi@avdi.org \ --cc=emacs-orgmode@gnu.org \ --subject='Re: Feature request for noweb mode that strips references on export' \ /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
Code repositories for project(s) associated with this 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).