examples/requiredvariables.ps1

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
properties {
  $x = $null
  $y = $null
  $z = $null
}

task default -depends TestRequiredVariables

# you can put arguments to task in multiple lines using `
task TestRequiredVariables `
  -description "This task shows how to make a variable required to run task. Run this script with -properties @{x = 1; y = 2; z = 3}" `
  -requiredVariables x, y, z `
{
}