On Tue, Jun 5, 2018 at 7:18 AM, Frederick Giasson <f...@curbside.com> wrote:
> There is one last thing related to =org-babel-detangle= that seems "broken"
> is that as far as I can see, the top =save-excursion= should save the
> position of the cursor of the source file and keep the buffer at that
> position when we perform a detangling on it, no?
>
> Right now, the behavior is that when we do a detangle from a source file,
> the org file get opened in the buffer of the source file.
>
> However, I think that the right behavior is that when we detangle that the
> remain at the same position in the source file otherwise this gets confusing
> in my opinion.
>
> Is that a bug or the expected behavior?

I think it is expected. The code looks like this:

(when (setq new-body (org-babel-tangle-jump-to-org))
      (org-babel-update-block-body new-body))

The first time I detangled I was surprised, too.

But then it hit me: if you are detangling then you probably might want to
1. See the updated code
2. Commit the updated code

So now I like it.

Reply via email to