Disable-ExperimentalFeature
Disable an experimental feature on startup of new instance of PowerShell.
Syntax
Disable-ExperimentalFeature
[-Name] <String[]>
[-Scope <ConfigScope>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Disable-ExperimentalFeature
cmdlet disables experimental features by removing the named
experimental features from the powershell.config.json
settings file read on PowerShell startup.
This cmdlet was introduced in PowerShell 6.2.
Note
Any changes to experimental feature state only takes effect on restart of PowerShell
Examples
Example 1: Disable an experimental feature
In this example, if this experimental feature was previously enabled, then the powershell.config.json
file is updated for the user to not enable that feature once PowerShell is restarted.
Upon success nothing is output to the pipeline and only a warning message is displayed.
Disable-ExperimentalFeature -Name PSImplicitRemotingBatching
WARNING: Enabling and disabling experimental features do not take effect until next start of PowerShell.
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Name
The name or names of the experimental features to disable.
Type: | String[] |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Scope
Determines which powershell.config.json
to update whether it affects all users or
just the current user.
Type: | ConfigScope |
Accepted values: | AllUsers, CurrentUser |
Position: | Named |
Default value: | CurrentUser |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
Pipe instances of ExperimentalFeature from Get-ExperimentalFeature
cmdlet to disable.
Outputs
None
This cmdlet returns no output.
Notes
Changes to state of an experimental feature only take effect on restart of PowerShell.