emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Feature request for noweb mode that strips references on export


From: Eric Schulte
Subject: Re: [O] Feature request for noweb mode that strips references on export
Date: Wed, 01 Feb 2012 08:21:58 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.92 (gnu/linux)

Avdi Grimm <address@hidden> 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/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]