* BUG org-babel-goto-named-src-block with indented block
@ 2014-02-26 9:32 Andreas Leha
2014-03-06 21:16 ` Eric Schulte
0 siblings, 1 reply; 4+ messages in thread
From: Andreas Leha @ 2014-02-26 9:32 UTC (permalink / raw)
To: emacs-orgmode
Hi all,
there seems to be a bug, where org-babel-goto-named-src-block does not
find an indented source block.
Here is an example:
--8<---------------cut here---------------start------------->8---
* Test org-babel-goto-named-src-block
Try org-babel-goto-named-src-block (C-c C-v g) with point on the
following line. (This works for me.)
#+call: block1(20)
Try org-babel-goto-named-src-block (C-c C-v g) with point on the
following line. (This does not work for me.)
#+call: block2(20)
** The first block *without* indentation
#+name: block1
#+header: :var end=10
#+begin_src R
1:end
#+end_src
** The second block *with* indentation
#+name: block2
#+header: :var end=11
#+begin_src R
2:end
#+end_src
--8<---------------cut here---------------end--------------->8---
Regards,
Andreas
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: BUG org-babel-goto-named-src-block with indented block
2014-02-26 9:32 BUG org-babel-goto-named-src-block with indented block Andreas Leha
@ 2014-03-06 21:16 ` Eric Schulte
2014-03-07 7:56 ` Andreas Leha
0 siblings, 1 reply; 4+ messages in thread
From: Eric Schulte @ 2014-03-06 21:16 UTC (permalink / raw)
To: Andreas Leha; +Cc: emacs-orgmode
Hi Andreas,
The problem is with your example. You can not put a header line between
a #+name and it's source block.
Best,
Andreas Leha <andreas.leha@med.uni-goettingen.de> writes:
> Hi all,
>
> there seems to be a bug, where org-babel-goto-named-src-block does not
> find an indented source block.
>
> Here is an example:
>
> --8<---------------cut here---------------start------------->8---
> * Test org-babel-goto-named-src-block
>
> Try org-babel-goto-named-src-block (C-c C-v g) with point on the
> following line. (This works for me.)
> #+call: block1(20)
>
>
> Try org-babel-goto-named-src-block (C-c C-v g) with point on the
> following line. (This does not work for me.)
> #+call: block2(20)
>
>
> ** The first block *without* indentation
> #+name: block1
> #+header: :var end=10
> #+begin_src R
> 1:end
> #+end_src
>
>
> ** The second block *with* indentation
> #+name: block2
> #+header: :var end=11
> #+begin_src R
> 2:end
> #+end_src
> --8<---------------cut here---------------end--------------->8---
>
>
> Regards,
> Andreas
>
>
--
Eric Schulte
https://cs.unm.edu/~eschulte
PGP: 0x614CA05D
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: BUG org-babel-goto-named-src-block with indented block
2014-03-06 21:16 ` Eric Schulte
@ 2014-03-07 7:56 ` Andreas Leha
2014-03-07 15:28 ` Eric Schulte
0 siblings, 1 reply; 4+ messages in thread
From: Andreas Leha @ 2014-03-07 7:56 UTC (permalink / raw)
To: emacs-orgmode
Hi Eric,
thanks for looking into this!
Eric Schulte <schulte.eric@gmail.com> writes:
> Hi Andreas,
>
> The problem is with your example. You can not put a header line between
> a #+name and it's source block.
>
If that is the case, then the manual should be fixed. As the manual
explicitly allows that: See the last example on here [fn:1].
Regards,
Andreas
Footnotes:
[fn:1]
http://orgmode.org/manual/Code-block-specific-header-arguments.html#Code-block-specific-header-arguments
> Best,
>
> Andreas Leha <andreas.leha@med.uni-goettingen.de> writes:
>
>> Hi all,
>>
>> there seems to be a bug, where org-babel-goto-named-src-block does not
>> find an indented source block.
>>
>> Here is an example:
>>
>> --8<---------------cut here---------------start------------->8---
>> * Test org-babel-goto-named-src-block
>>
>> Try org-babel-goto-named-src-block (C-c C-v g) with point on the
>> following line. (This works for me.)
>> #+call: block1(20)
>>
>>
>> Try org-babel-goto-named-src-block (C-c C-v g) with point on the
>> following line. (This does not work for me.)
>> #+call: block2(20)
>>
>>
>> ** The first block *without* indentation
>> #+name: block1
>> #+header: :var end=10
>> #+begin_src R
>> 1:end
>> #+end_src
>>
>>
>> ** The second block *with* indentation
>> #+name: block2
>> #+header: :var end=11
>> #+begin_src R
>> 2:end
>> #+end_src
>> --8<---------------cut here---------------end--------------->8---
>>
>>
>> Regards,
>> Andreas
>>
>>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: BUG org-babel-goto-named-src-block with indented block
2014-03-07 7:56 ` Andreas Leha
@ 2014-03-07 15:28 ` Eric Schulte
0 siblings, 0 replies; 4+ messages in thread
From: Eric Schulte @ 2014-03-07 15:28 UTC (permalink / raw)
To: Andreas Leha; +Cc: emacs-orgmode
>> The problem is with your example. You can not put a header line between
>> a #+name and it's source block.
>>
>
> If that is the case, then the manual should be fixed. As the manual
> explicitly allows that: See the last example on here [fn:1].
>
Oh, thanks for pointing this out.
Given the manual example I would like to reverse my previous statement.
I suppose it *is* legal to separate a name and code block by intervening
comment or header lines. I've just pushed up a fix which allows your
original example to work as written.
Thanks for following up on this!
>
> Regards,
> Andreas
>
>
> Footnotes:
>
> [fn:1]
> http://orgmode.org/manual/Code-block-specific-header-arguments.html#Code-block-specific-header-arguments
>
>
>
>> Best,
>>
>> Andreas Leha <andreas.leha@med.uni-goettingen.de> writes:
>>
>>> Hi all,
>>>
>>> there seems to be a bug, where org-babel-goto-named-src-block does not
>>> find an indented source block.
>>>
>>> Here is an example:
>>>
>>> --8<---------------cut here---------------start------------->8---
>>> * Test org-babel-goto-named-src-block
>>>
>>> Try org-babel-goto-named-src-block (C-c C-v g) with point on the
>>> following line. (This works for me.)
>>> #+call: block1(20)
>>>
>>>
>>> Try org-babel-goto-named-src-block (C-c C-v g) with point on the
>>> following line. (This does not work for me.)
>>> #+call: block2(20)
>>>
>>>
>>> ** The first block *without* indentation
>>> #+name: block1
>>> #+header: :var end=10
>>> #+begin_src R
>>> 1:end
>>> #+end_src
>>>
>>>
>>> ** The second block *with* indentation
>>> #+name: block2
>>> #+header: :var end=11
>>> #+begin_src R
>>> 2:end
>>> #+end_src
>>> --8<---------------cut here---------------end--------------->8---
>>>
>>>
>>> Regards,
>>> Andreas
>>>
>>>
>
>
--
Eric Schulte
https://cs.unm.edu/~eschulte
PGP: 0x614CA05D
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-03-07 15:30 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-26 9:32 BUG org-babel-goto-named-src-block with indented block Andreas Leha
2014-03-06 21:16 ` Eric Schulte
2014-03-07 7:56 ` Andreas Leha
2014-03-07 15:28 ` Eric Schulte
Code repositories for project(s) associated with this public 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).