User Tools

Site Tools


commands:zone_commands:select

select: <conditions1> | <conditions2> :: <command1> :: <command2> :: <default>

The select command allows for more sophisticated branching than the bracket prefix to a single command. An arbitrary number of conditions can be used - at least same number of commands must be supplied - or an extra command can be supplied as a default which will be run if none of the conditions are met. Note that if multiple conditions are met, on the first condition/command pair will be executed.

  • conditions are the conditions to be tested; for multiple conditions to be tested, use a comma-separated list; this is one occasion where the old syntax of separating conditionals with pipes | cannot be used.
  • commands are the commands that will be executed when the related condition is met
  • default is an optional command that will be executed if no conditions are met.
commands/zone_commands/select.txt · Last modified: by 127.0.0.1