emacs-orgmode
[Top][All Lists]
Advanced

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

[O] src block: 'C-c C-c can do nothing useful here' if cursor on blank l


From: John Hendy
Subject: [O] src block: 'C-c C-c can do nothing useful here' if cursor on blank line
Date: Fri, 27 Jan 2017 12:44:07 -0600

Perhaps this is the intended behavior, but I noticed that I go to
execute a code block and get the message "C-c C-c can do nothing
useful here" if I'm not on the actual src block definition or a line
of code. If I'm on a blank line inside it, it doesn't execute. Here
was my test:

#+begin min_config

(add-to-list 'load-path "~/.elisp/org/lisp/")
(add-to-list 'load-path "~/.elisp/org/contrib/lisp")

(org-babel-do-load-languages
 'org-babel-load-languages
 '((R . t)))

#+end

Start with =emacs -Q= and then =M-x load-file RET
~/path/to/min-config=, then use this test file:

* heading

#+begin_src R
^
x <- 1:10
x

#+end_src

With the cursor at ^ it won't run. I would understand if this were in
interactive mode using =C-c '=, but the behavior of C-c C-c is to run
the whole block anyway. It seems like Org doesn't know I'm in a src
block. Since blank lines are common, I'd expect not to have to make
*sure* I'm on an actual line of code and that being anywhere in a src
block should work.

Thoughts?


Thanks,
John



reply via email to

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