Previous: gml, Up: General usage information


3.4 Setting parameters from the commandline

Gmerlin configuration handling provides the same features for both GUI applications and commandline programs. The natural result is, that the commandline syntax is a bit more complicated, since parameters can be nested.

In General options have the form

'parameter1=value1:parameter2=value2...'

The quotes are necessary, if the string contains characters, which have a special meaning for the shell.

The syntax of values depends on the type:

Boolean
Value can be either 0 or 1.
Integer values
An integer number.
Float values
A floating point (i.e. fractional) number.
Strings
A string. Colons ':' should be escaped with '\'.
Time
Time is in the format {[[HH:]MM:]SS} while the seconds can be fractional. Hours and Minutes are optional, thus any format of {5.5}, {0:05.5} or {0:00:05.5} is valid for a time of 5.5 seconds. Writing 0 instead of 00 is also ok.
Enumeration with suboptions
Value is in the form string[{subparameter1=subvalue1:subparameter2=subvalue2...}]. The subparameters are optional. E.g. if the option is for selecting a plugin, setting string to foo will select the plugin foo and pass the subparameters (if avaliable) to the foo plugin.
List or chain with suboptions
This is like enumeration with suboptions with the difference, that you can concatenate multiple options together with colons (:) and must enclose everything with braces. For example:

{opt1{param1=value1}:opt2{param2=value2}}

If you use -help, you'll also see supported ranges for numeric types, or supported options for strings (if available).