emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] tangling order


From: Charles C. Berry
Subject: Re: [O] tangling order
Date: Tue, 16 Feb 2016 09:34:22 -0800
User-agent: Alpine 2.20 (OSX 67 2015-01-07)

On Tue, 16 Feb 2016, Alan Schmitt wrote:

On 2016-02-16 12:42, John Kitchin <address@hidden> writes:

I think you are seeing that the blocks are tangled in reverse. If I add a third
arbitrary lang it comes in reverse.

Interesting! Thanks a lot for trying it.

I see that I made the typical scientific method mistake of testing for
my hypothesis, instead of testing against.

If they are all the same language, they are in the right order. It looks like
org collects by language, so your strategy won't work with org-babel tangle I
guess.

I've found a workaround, as it is only for a few blocks I manually
change their headers, so it is fine at the moment.

Another workaround would be to add after advice to `org-babel-get-src-block-info' to map your faux languages to a common variant.

I still think it
would be great to have better control on the order in which blocks are
tangled.

If you want to do this inside org/emacs (and not stitch a bunch of tangled files together with other tools), try this in your *.org file and execute it. The result is what you might work with (i.e. customize or advice the function below).

#+BEGIN_SRC emacs-lisp :results pp :tangle foo.ml
(org-babel-tangle-collect-blocks)
#+END_SRC


HTH,

Chuck





reply via email to

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