API Reference
Command
Stop-CxWslDistribution
Stops a WSL distribution through the native public WSL API.
Examples
Example 1: Preview stopping a WSL distribution.
PS>
Stop-CxWslDistribution -Name Ubuntu-22.04 -Preview
Example 2: Stop a WSL distribution through the native API.
PS>
Stop-CxWslDistribution -Name Ubuntu-22.04 -Confirm
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
Stop-CxWslDistribution -Name <string> [-Preview] [<CommonParameters>]#Parameters
- Name string
- Distribution name.
- Preview SwitchParameter
- Emits the non-mutating termination plan without invoking the native API.
Outputs
ComputerX.Wsl.WslDistributionStopPlan, ComputerX.Wsl.WslDistributionStopResult