emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [Feature request] String escaped noweb expansion


From: Tom Gillespie
Subject: Re: [Feature request] String escaped noweb expansion
Date: Sun, 2 May 2021 11:34:22 -0700

Hi Sebastien,
    I have encountered issues with this before when trying to noweb code
into a string that was code to be sent via ssh. I ended up switching
to use typeset -f in bash in most cases now, but that is not possible
for other languages. Some languages also have enough different types
of syntax for strings that they can work around such cases, but again,
not all do.

One potential issue with this suggestion is how it would interact with
multi-line blocks, because you can't have anything on the same
starting line as the noweb expressions since it will be repeated in
front of every subsequent line.

This would also require each org-babel lang implementation to provide
a method for correctly string-escaping the nowebbed values (in some
cases e.g. shell this is decidedly non-trivial).

With all of these things in mind, I would thus suggest not trying to
overload the noweb operator for this purpose. Having a string escaped
equivalent would be nice, but because it requires more than just a
simple copy/paste into the buffer, it seems like it probably needs
separate notation. Best,
Tom



reply via email to

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