Petals CLI 2.1.2+

compared with
Key
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (1)

View Page History
{code}

h2. Working with variables

Petals CLI supports variables as properties. A variable is a placeholder with a name: {{${variable-name\}}}, that is replaced by its value when evaluating the command in which it is used.
{code}
connect -h ${host.name} -n ${host.port} -u ${host.user} -p ${host.password}
{code}

h3. Listing available variables

The command '_set_' without argument lists all available variables:
{code}
> ./petals-cli.sh -C

Type 'help' for help.
------------------------------------------------------------------------------
petals-cli> set
...
java.runtime.name=Java(TM) SE Runtime Environment
java.runtime.version=1.6.0_45-b06
java.specification.name=Java Platform API Specification
java.specification.vendor=Sun Microsystems Inc.
java.specification.version=1.6
...
{code}

h3. Setting a variable as property

A property can be set using the command '_set_':
{code}
set [ property-name = property-value ]
set [ property-name =: property-value ]
set [ property-name : property-value ]
{code}

h2. Return codes of Petals CLI