- 07 Nov 2024
- 2 Minutes to read
- Print
- DarkLight
- PDF
Variables
- Updated on 07 Nov 2024
- 2 Minutes to read
- Print
- DarkLight
- PDF
Get-LiquitVariable
Synopsis
This command displays a list of all the variables available within Liquit Workspace. Alternatively, you can select a specific variable.
See Variables for a complete list of all predefined variables within Liquit Workspace.
Syntax
Get-LiquitVariable
[[-ID] <string[]>]
[-Inherited]
[-LiquitContext <LiquitContext>]
[<CommonParameters>]
Get-LiquitVariable
[-Context] <Context>
[[-ID] <string[]>]
[-Inherited]
[-LiquitContext <LiquitContext>]
[<CommonParameters>]
Get-LiquitVariable
[-Snapshot] <PackageSnapshot>
[[-ID] <string[]>]
[-Inherited]
[-LiquitContext <LiquitContext>]
[<CommonParameters>]
Examples
Example 1: Get-LiquitVariable
Get-LiquitVariable
This command displays all variables defined within Liquit Workspace.
Example 2: Get-LiquitVariable
Get-LiquitVariable -ID 00000000-0000-0000-0000-000000000000
This command displays the selected variable.
New-LiquitVariable
Synopsis
This command creates or updates an existing variable (in a zone, context or package snapshot). This cmdlet has the same behaviour as Set-LiquitVariable.
Syntax
New-LiquitVariable
[-ID] <string[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
New-LiquitVariable
[-Variable] <Variable[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
New-LiquitVariable
[-Snapshot] <PackageSnapshot[]>
[-ID] <string[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
New-LiquitVariable
[-Context] <Context[]>
[-ID] <string[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Example
New-LiquitVariable -ID "PowerShell Variable" -Value "PowerShell Value"
This command creates a new variable with the id "PowerShell Variable" and the value "PowerShell Value".
Parameters
Name | Value | Description | Required | Default value |
---|---|---|---|---|
ID | <string[]> | The ID the variable should have. | New variables | |
Sensitive | A switch parameter you can use to set the variable as sensitive case. | |||
Value | <string> | The value of the variable. | No | |
Variable | <Variable[]> | The variable you want to edit. | Existing variables | |
Snapshot | <PackageSnapshot[]> | The snapshot to which you want to assign the variable. | Snapshot only | |
LiquitContext | <LiquitContext> | Determines the selected zone. | No | Default |
Set-LiquitVariable
Synopsis
This command lets you edit the properties of a variable.
Syntax
Set-LiquitVariable
[-ID] <string[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-LiquitVariable
[-Variable] <Variable[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-LiquitVariable
[-Snapshot] <PackageSnapshot[]>
[-ID] <string[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-LiquitVariable
[-Context] <Context[]>
[-ID] <string[]>
[-Value] <string>
[[-Sensitive]]
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Example
Set-LiquitVariable -ID "PowerShell Variable" -Value "PowerShell Value"
This command creates a new variable with the id “PowerShell Variable” and the value “PowerShell Value”.
Parameters
Name | Value | Description | Required | Default value |
---|---|---|---|---|
ID | <string[]> | The ID the variable should have. | New variables | |
Value | <string> | The value of the variable. | No | |
Variable | <Variable[]> | The variable you want to edit. | Existing variables | |
Snapshot | <PackageSnapshot[]> | The snapshot to which you want to assign the variable. | Snapshot only | |
Sensitive | A switch parameter you can use to set the variable as sensitive case. | |||
LiquitContext | <LiquitContext> | Determines the selected zone. | No | Default |
Clear-LiquitVariable
Synopsis
This command clears a variable.
Syntax
Clear-LiquitVariable
[-ID] <string[]>
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Clear-LiquitVariable
[-Variable] <Variable[]>
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Clear-LiquitVariable
[-Snapshot] <PackageSnapshot[]>
[-ID] <string[]>
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Clear-LiquitVariable
[-Context] <Context[]>
[-ID] <string[]>
[-LiquitContext <LiquitContext>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Example
$variable = Get-LiquitVariable -ID "PowerShell Variable"
Clear-LiquitVariable -Variable $variable
This command removes the selected variable.
Parameters
Name | Value | Description | Required | Default value |
---|---|---|---|---|
ID | <string[]> | The ID of the variable you want to remove. | Id and snapshot | |
Variable | <Variable[]> | The variable you want to remove. | Variable only | |
Snapshot | <PackageSnapshot[]> | The snapshot containing the variable you want to remove. | Snapshot only | |
Context | <Context[]> | The context containing the variable you want to remove. | Context only | |
LiquitContext | <LiquitContext> | Determines the selected zone. | No | Default |