[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Setting multiple variables for code blocks in one property drawe
From: |
Viktor Rosenfeld |
Subject: |
Re: [O] Setting multiple variables for code blocks in one property drawer |
Date: |
Mon, 20 Feb 2012 12:43:20 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Hi Eric,
Eric Schulte wrote:
> Viktor Rosenfeld <address@hidden> writes:
>
> > Hi Eric,
> >
> > thanks for your input. I just pulled the latest code from git and while
> > my original example works, the following does not:
> >
> > :PROPERTIES:
> > :var: foo=1
> > :var+: bar=2
> > :var+: baz=3
> > :END:
> >
> > #+BEGIN_SRC sh
> > echo foo: $foo
> > echo bar: $bar
> > echo baz: $baz
> > #+END_SRC
> >
>
> Thanks for reporting, I've just pushed up a fix for this bug.
Thanks for your fix. The above example now works for me.
However, I've noticed a problem with inheriting var properties. They are
inherited in a child task only if the child task itself has no var
property. Is this the intended behavior? See the example below.
Cheers,
Viktor
* Parent task
:PROPERTIES:
:var: foo="1"
:var+: bar="2"
:END:
** Child task without own properties
#+BEGIN_SRC sh
echo foo: $foo
echo bar: $bar
#+END_SRC
#+RESULTS:
| foo: | 1 |
| bar: | 2 |
** Child task with own properties
:PROPERTIES:
:var: foo="a"
:END:
#+BEGIN_SRC sh
echo foo: $foo
echo bar: $bar
#+END_SRC
#+RESULTS:
| foo: | a |
| bar: | |