I've applied the FELIX-1471 patch to Karaf and get an exception when using
assignment with grouping:
ka...@root> x = (echo a; echo b)
org.osgi.framework.InvalidSyntaxException: expected value|substring
at org.apache.felix.framework.FilterImpl.<init>(FilterImpl.java:81)
In RFC132 parens () were used to create an LDAP filter - it looks like it's
still trying to do that in an assignment.
Using $() works OK:
ka...@root> x = $(echo a; echo b)
a
b
But if () are supposed to be used for grouping, then I shouldn't need to use
$()?
Is the FELIX-1325 patch dependent on the FELIX-1471 patch?
I also noticed that shell:echo doesn't print a space between its last two
arguments:
ka...@root> shell:echo 1 2 3 4 5
1 2 3 45
Derek
2009/8/16 Guillaume Nodet <[email protected]>
> I've attached 2 patches to FELIX-1471 and FELIX-1325 to fix those issues.
> Ftr, those are:
> * use () for command grouping and $() for evaluation
> * throw an exception when a command is not found, even if it has no
> arguments
>
> Feedback welcome.
>
> On Wed, Aug 12, 2009 at 21:06, Guillaume Nodet <[email protected]> wrote:
>
> > I'll try to come up with a patch for further discussion.
> > I think the grouping operator (...) will be handled directly by the
> parser
> > without surfacing to the closure and pipes interpreters, while the $(...)
> > for evaluation would be handled by those the way <...> currently works.
> >
> >
> > On Wed, Aug 12, 2009 at 15:37, Richard S. Hall <[email protected]
> >wrote:
> >
> >> On 8/12/09 4:00, Guillaume Nodet wrote:
> >>
> >>> So I'd rather have ( ... ) for pure grouping and $( ... ) for
> evaluating
> >>> as
> >>> we have in bash.
> >>>
> >>>
> >>>
> >>
> >> That seems reasonable to me.
> >>
> >> -> richard
> >>
> >>
> >>
> >
> >
> > --
> > Cheers,
> > Guillaume Nodet
> > ------------------------
> > Blog: http://gnodet.blogspot.com/
> > ------------------------
> > Open Source SOA
> > http://fusesource.com
> >
> >
> >
>
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> ------------------------
> Open Source SOA
> http://fusesource.com
>