emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <mail@nicolasgoaziou.fr>
To: Ken Mankoff <mankoff@gmail.com>
Cc: Org Mode <emacs-orgmode@gnu.org>
Subject: Re: org-babel-expand-src-block behavior
Date: Mon, 14 Aug 2017 16:25:14 +0200	[thread overview]
Message-ID: <87inhq8bw5.fsf@nicolasgoaziou.fr> (raw)
In-Reply-To: <CAFdBzEqEgfbcQ5=LXRuMgAzrsrfyNTBW=-WSBo-Y8Kcuej=agA@mail.gmail.com> (Ken Mankoff's message of "Sat, 12 Aug 2017 20:11:40 +0200")

Hello,

Ken Mankoff <mankoff@gmail.com> writes:

> Is there a way to get variables into org-edit-special? Maybe by pre-pending
> C-u to C-c '?

The problem is not getting the variables into the remote editing buffer.
As you noticed, we would only need to remove the read-only status from
`org-babel-expand-src-block' output. The difficulty is writing back to
the source buffer. You need to mark somehow the original contents of the
src block and be able to retrieve it upon exiting the buffer.

Also, the remote editing buffer is not really suited for debugging.
Since it is not associated to a file, some compilers refuse to run the
code in there (e.g., asymptote blocks).

> How do others debug code with input variables?

I expand everything, copy it and write it into a temporary file. I do
the debugging in the temp file. When I'm satisfied, I copy the contents
of the file back into the remote editing buffer. Nothing fancy.


Regards,

-- 
Nicolas Goaziou

      reply	other threads:[~2017-08-14 14:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-12  4:40 org-babel-expand-src-block behavior Ken Mankoff
2017-08-12 10:52 ` Nicolas Goaziou
2017-08-12 18:11   ` Ken Mankoff
2017-08-14 14:25     ` Nicolas Goaziou [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87inhq8bw5.fsf@nicolasgoaziou.fr \
    --to=mail@nicolasgoaziou.fr \
    --cc=emacs-orgmode@gnu.org \
    --cc=mankoff@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).