[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] How to specify the tangled comment to be the location of the now
From: |
Eric Schulte |
Subject: |
Re: [O] How to specify the tangled comment to be the location of the noweb ref definition instead of where it was tangled? |
Date: |
Thu, 12 Jun 2014 15:46:22 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
>
> How do I make the code comment specify the actual location of the source block
> ref, not just where it was expanded and tangled?
>
Currently inserting comments around snippets of code expanded with noweb
is not supported. You may be able to fake this through the clever use
of variables along the lines of the following,
#+begin_src sh :var start=(line-number-at-pos (point)) :results scalar
cat <<EOF
# started at $start
foo bar baz
EOF
#+end_src
or an implementation of optional wrappers for noweb-expanded snippets
would probably start with the `org-babel-expand-noweb-references'
function.
Best,
Eric
--
Eric Schulte
https://cs.unm.edu/~eschulte
PGP: 0x614CA05D (see https://u.fsf.org/yw)