On Tue, Oct 25, 2011 at 12:31 PM, Sebastien Vauban <
wxhgmqzgw...@spammotel.com> wrote:

> Hi Rainer,
>
> Rainer M Krug wrote:
> >> While thinking about all of this, and working in real-life documents, I
> >> just
> >> came back to a suggestion which I made some time ago. It goes about this
> >> enhancement:
> >>
> >>    Would it be possible to specify "buffer-wide language specific"
> header
> >>    arguments?
> >>
> >> That is, be able to say:
> >>
> >>    "In this document, I want to:
> >>    - tangle all my .sql chunks, but no other;
> >>    - eval all the elisp chunks with query, but no other."
> >>
> >> Something we could write quite easily along the lines:
> >>
> >>    #+PROPERTY:               tangle no
> >>    #+PROPERTY:               eval never
> >>    #+PROPERTY[SQL]:          tangle yes
> >>    #+PROPERTY[EMACS-LISP]:   eval query
> >>
> >>    (the syntax used here is just a draft sample!)
> >>
> >> What do you think about this feature? If you feel it can be something
> >> interesting to have, this is surely to incorporate in the current syntax
> >> debate. If not... never mind.
> >
> > I am not Eric, but I think that would be a good idea.
>
> Thanks for your comments.
>
> > Bu there needs to be a way of specifying more then one property, either
> > by #+PROPERTY+: or by any other way -I acually luike the #+PROPERTY+: .
> > Thinking about it, it should be possible without the +:
> >
> > #+PROPERTY[R]: tangle no
> > #+PROPERTY[R]: export both
>
> Yes, no need for a "+" here, as the lines do target different properties
> (in
> this case, "tangle" and "export").
>
> > The more I see it, the more I like it - also the []
>
> In fact, the lines without any language specification would be, at least
> semantically, equivalent to something like this:
>
>      #+PROPERTY[*]:            tangle no
>      #+PROPERTY[*]:            eval never
>

So

#+PROPERTY followed by square brackets, means properties for source blocks
of a given language, and [*] is the default and can be omitted.

Two ideas: [R,sh], i.e. specifying a list of languages in the brackets could
be useful, as well as wildcards like [dit*]? The latter less usefull, but
for consistency?

Additionally: it would be nice, if one could define a set of properties, and
then recall them for certain blocks.

e.g:

#+PROPERTY[R:set1]: tangle no
#+PROPERTY[R:set1]: eval never

#+PROPERTY[R:set2]: tangle yes
#+PROPERTY[R:set2]: export both

#+src_begin R :set set1
  cat(1)
#+end

would have the first set of properties (tangle no and eval never), where

#+src_begin R :set set2
  cat(1)
#+end

would have the second set of properties (tangle no and eval never)

Might be a good addition?

Cheers,


Rainer


> Best regards,
>  Seb
>
> --
> Sebastien Vauban
>
>
>


-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology,
UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :       +33 - (0)9 53 10 27 44
Cell:       +33 - (0)6 85 62 59 98
Fax (F):       +33 - (0)9 58 10 27 44

Fax (D):    +49 - (0)3 21 21 25 22 44

email:      rai...@krugs.de

Skype:      RMkrug

Reply via email to