Karaf shell not echoing some variable values

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Karaf shell not echoing some variable values

Aaron Hoffer
Until recently, the Karaf shell printed the value of variables. For example,
entering "$.variables" like this:

     karaf@root()> $.variables    

would print a list of the variables in the shell's environment. I downloaded
Karaf 4.2.0 yesterday and this behavior has changed. Entering $.variables at
the shell prompt prints nothing:

    karaf@root()> $.variables                                                                                                    

To get the list of .variables, I have to pipe the invocation to cat:

     karaf@root()> $.variables | cat

The same behavior happens with variables defined at the shell prompt. For

     karaf@root()> temp=42
     karaf@root()> $temp

I  can use echo to get the value:

     karaf@root()> echo $temp

Other variables print their values as expected:

     karaf@root()> $java.version

I reviewed the changelog but did not find any mention of it. I search the
forums for "variables" and "shell", but the search came up empty.  Was the
change in behavior intentional or unintentional? If it was unintentional,
should I create an issue to track it?

Sent from: http://karaf.922171.n3.nabble.com/Karaf-User-f930749.html