[Top][All Lists]

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

Re: [O] [ANN] BREAKING CHANGE -- removing #+BABEL file-wide property lin

From: Sebastien Vauban
Subject: Re: [O] [ANN] BREAKING CHANGE -- removing #+BABEL file-wide property lines
Date: Tue, 25 Oct 2011 11:35:35 +0200
User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (windows-nt)

Hi Eric,

Eric Schulte wrote:
>> #+BABEL: :var SVNVERSION=(vc-working-revision (buffer-file-name))
>> #+BABEL: :var SVNSTATE=( symbol-name (vc-state (or (buffer-file-name) 
>> org-current-export-file)))
>> #+BABEL: :var SVNSTATENUM=(if (eq (vc-state (or (buffer-file-name) 
>> org-current-export-file)) 'up-to-date) 0 13)
>> which would look horrible in one line and a nightmare to edit.
> I can think of three options for how to handle this situation.
> 1. If it turns out to be possible/desirable my preferred solution here
>    would be to add general property support for appending values to
>    properties when properties are over specified rather than simply
>    replacing the value.  Perhaps this could be done with a variable like
>    org-accumulating-properties which could hold a list of those
>    properties which should accumulate values rather than overwriting
>    them.
> 2. Adding a "#+PROPERTY:" line authoring helper similar to the table
>    formula helper making it more natural to edit such long property
>    lines.
> 3. It may be possible to add syntax for extending #+PROPERTY:
>    specifications across multiple lines, something like
>    #+PROPERTY: SVNVERSION=(vc-working-revision (buffer-file-name)),
>    #+PROPERTY+: SVNSTATE=( symbol-name (vc-state (or (buffer-file-name) 
> org-current-export-file))),
>    #+PROPERTY+: SVNSTATENUM=(if (eq (vc-state (or (buffer-file-name) 
> org-current-export-file)) 'up-to-date) 0 13),
>    FWIW I would like to have a similar extender for #+TBLFM: lines.
>    Actually this choice may be my preferred solution.
> What do you think?

I think that makes sense.

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

    Would it be possible to specify "buffer-wide language specific" header

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.

Best regards,

Sebastien Vauban

reply via email to

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