[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames
From: |
Jambunathan K |
Subject: |
[Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames |
Date: |
Thu, 09 Sep 2010 21:08:54 +0530 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.91 (windows-nt) |
> Jambu> I think there is a strong case for making headlines act as babel
> Jambu> srcnames with their body providing content for noweb expansion
> Jambu> [3]. This behaviour could be controlled by a buffer local
> Jambu> variable.
I have some more thoughts on this. Let me capture it before it goes
away. My thoughts are fragmented and my only request is that it be noted
and embraced and extended when you hash out the final details.
I think value of Babel could be tremendously enhanced if '#+results ...'
are revisited and redefined.
So that not I sound too abstract, let us take an example.
Remember the recent thread [1] where there was a request to
automagically 'embed' the revision number of a document in an orgmode
file? This is what emerged as a solution that the original poster was
happy with.
> ,----
> | * revision control
> | The version of this file is
> | src_emacs-lisp{(vc-working-revision (or (buffer-file-name) org-current-:
> export-file))}.
> `----
IMHO, I believe there is an opportunity for improvement. What if the
actual solution ended up like the following ...
* Revision
#+begin_src emacs-lisp
(vc-working-revision (or (buffer-file-name) org-current-export-file))
#+end_src
# Variant-1:
* revision control
Version of the file is <<Revision()>>
# Variant-2:
Or better still something like this
* revision control
Version of the file [[<<Revision()>>][Rev-1]]
Following items are worthy of note:
1. The body of the headline is provided by executing the blocks
undeneath it.
Worth comparing this with the idea that emerged in the original post
- where the content of the headline is provided by the user (for
example a pdf link or body of a letter) and the results of the
execution is one that obtained by piping the results through a custom
exporter (latex)
2. In both cases there is no notion of a '#+results ' being created.
3. In Variant-2, the org's notion of what a link is redefined (Remember
extensible link syntax proposed by Samuel Wales).
Let's look at how the link is defined in the example
[[<<Revision()>>][Rev-1]]
The url portion of the link is actually a 'babel macro call' and
provides the content. Note how the macro call is embedded in the url
portion and there by hidden from human eye and Rev-1 provides a
placeholder. The special link face (or may be a 'babel macro face')
would let the user know that there are more things lurking
underground.
Time to get abstract ...
As I see it, removing 'extra levels of indirection' as the 'results of
source block' travel through org document more the Babel workflow would
seemlessly integrate with org's world view.
In some sense Babel would be more successful if it does it's offices
under the hood and not really make it's presence felt to the person
editing the document :-).
Footnotes:
[1] http://thread.gmane.org/gmane.emacs.orgmode/29690/focus=29792 [2]
Jambunthan K.
- [Orgmode] Composing letters using Org mode and the LaTeX isodoc class, Sébastien Vauban, 2010/09/07
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Jambunathan K, 2010/09/07
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Sébastien Vauban, 2010/09/07
- Re: [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Eric Schulte, 2010/09/07
- Re: [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Thomas S. Dye, 2010/09/07
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Jambunathan K, 2010/09/08
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Sébastien Vauban, 2010/09/08
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Eric Schulte, 2010/09/08
- [Orgmode] [BABEL][PROPOSAL] headlines as executable srcnames, Jambunathan K, 2010/09/08
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames, Sébastien Vauban, 2010/09/08
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames,
Jambunathan K <=
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames, Jambunathan K, 2010/09/09
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames, Jambunathan K, 2010/09/10
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames, Eric Schulte, 2010/09/20
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames, Jambunathan K, 2010/09/20
- [Orgmode] Re: [BABEL][PROPOSAL] headlines as executable srcnames, Eric Schulte, 2010/09/20
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Sébastien Vauban, 2010/09/08
- Re: [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Eric Schulte, 2010/09/08
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Sébastien Vauban, 2010/09/08
- Re: [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Eric S Fraga, 2010/09/10
- [Orgmode] Re: Composing letters using Org mode and the LaTeX isodoc class, Sébastien Vauban, 2010/09/10