Removes a local group.
Uninstall-Group [-Name] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
The Uninstall-Group
function removes a local group using .NET's DirectoryServices.AccountManagement API. If the group doesn't exist, returns without doing any work or writing any errors.
This function was added in Carbon 2.1.0.
Name | Type | Description | Required? | Pipeline Input | Default Value |
---|---|---|---|---|---|
Name | String | The name of the group to remove/uninstall. |
true | false | |
WhatIf | SwitchParameter | false | false | ||
Confirm | SwitchParameter | false | false | ||
CommonParameters | This cmdlet supports common parameters. For more information type Get-Help about_CommonParameters . |
Uninstall-WhsGroup -Name 'TestGroup1'
Demonstrates how to uninstall a group. In this case, the TestGroup1
group is removed.