Uninstall-Script
Uninstalls a script.
構文
NameParameterSet (既定)
Uninstall-Script
[-Name] <String[]>
[-MinimumVersion <String>]
[-RequiredVersion <String>]
[-MaximumVersion <String>]
[-Force]
[-AllowPrerelease]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
InputObject
Uninstall-Script
[-InputObject] <PSObject[]>
[-Force]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
説明
The Uninstall-Script
cmdlet uninstalls a specified script from the local computer.
This is a proxy cmdlet for the Uninstall-PSResource
cmdlet in the
Microsoft.PowerShell.PSResourceGet. For more information, see
Uninstall-PSResource.
例
Example 1: Uninstall a script
This example uninstalls a script.
Uninstall-Script -Name UpdateManagement-Template
Uninstall-Script
uses the Name parameter to specify the script to uninstall from the local
computer.
Example 2: Use the pipeline to uninstall a script
In this example, the pipeline is used to uninstall a script.
Get-InstalledScript -Name UpdateManagement-Template | Uninstall-Script
Get-InstalledScript
uses the Name parameter to specify the script. The object is sent down the
pipeline to Uninstall-Script
and the script is uninstalled.
パラメーター
-AllowPrerelease
The proxy cmdlet maps this parameter to the Prerelease parameter of Uninstall-PSResource
.
パラメーターのプロパティ
型: | SwitchParameter |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
NameParameterSet
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | False |
残りの引数からの値: | False |
-Confirm
Prompts you for confirmation before running Uninstall-Script
.
パラメーターのプロパティ
型: | SwitchParameter |
規定値: | False |
ワイルドカードのサポート: | False |
DontShow: | False |
Aliases: | cf |
パラメーター セット
(All)
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | False |
残りの引数からの値: | False |
-Force
The proxy cmdlet ignores this parameter since it's not supported by Uninstall-PSResource
.
パラメーターのプロパティ
型: | SwitchParameter |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
(All)
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | False |
残りの引数からの値: | False |
-InputObject
Accepts a PSRepositoryItemInfo object. For example, output Get-InstalledScript
to a variable
and use that variable as the InputObject argument.
パラメーターのプロパティ
型: | PSObject[] |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
InputObject
配置: | 0 |
必須: | True |
パイプラインからの値: | True |
プロパティ名別のパイプラインからの値: | True |
残りの引数からの値: | False |
-MaximumVersion
The proxy cmdlet uses the value of this parameter to create a NuGet version search string for use
with the Version parameter of Uninstall-PSResource
.
パラメーターのプロパティ
型: | String |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
NameParameterSet
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | True |
残りの引数からの値: | False |
-MinimumVersion
The proxy cmdlet uses the value of this parameter to create a NuGet version search string for use
with the Version parameter of Uninstall-PSResource
.
パラメーターのプロパティ
型: | String |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
NameParameterSet
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | True |
残りの引数からの値: | False |
-Name
Specifies an array of script names to uninstall.
パラメーターのプロパティ
型: | String[] |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
NameParameterSet
配置: | 0 |
必須: | True |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | True |
残りの引数からの値: | False |
-RequiredVersion
The proxy cmdlet uses the value of this parameter to create a NuGet version search string for use
with the Version parameter of Uninstall-PSResource
.
パラメーターのプロパティ
型: | String |
規定値: | None |
ワイルドカードのサポート: | False |
DontShow: | False |
パラメーター セット
NameParameterSet
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | True |
残りの引数からの値: | False |
-WhatIf
Shows what would happen if Uninstall-Script
runs. The cmdlet isn't run.
パラメーターのプロパティ
型: | SwitchParameter |
規定値: | False |
ワイルドカードのサポート: | False |
DontShow: | False |
Aliases: | wi |
パラメーター セット
(All)
配置: | Named |
必須: | False |
パイプラインからの値: | False |
プロパティ名別のパイプラインからの値: | False |
残りの引数からの値: | False |
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.