external help file: Microsoft.WinGet.Client.Cmdlets.dll-Help.xml Module Name: Microsoft.WinGet.Client ms.date: 08/01/2024 online version: schema: 2.0.0 title: Repair-WinGetPackageManager
Repairs the installation of the WinGet client on your computer.
Repair-WinGetPackageManager [-AllUsers] [-Force] [-Version <String>] [-IncludePreRelease] [<CommonParameters>]
Repair-WinGetPackageManager [-AllUsers] [-Force] [-Latest] [-IncludePreRelease]
[<CommonParameters>]
This command repairs the installation of the WinGet client on your computer by installing the specified version or the latest version of the client. This command can also install the WinGet client if it is not already installed on your machine. It ensures that the client is installed in a working state.
Repair-WinGetPackageManagerEnsures that the current installed version of WinGet is functioning properly.
Repair-WinGetPackageManager -Latest -ForceThis example shows how to repair they WinGet client by installing the latest version and ensuring it functions properly. The Force parameter shuts down the version that is currently running so that it can update the application files.
Repair-WinGetPackageManager -Version "1.12.*" -ForceThis example shows how to repair the WinGet client by installing a version that matches the specified version pattern. The Force parameter shuts down the version that is currently running so that it can update the application files.
Use this parameter to repair the WinGet client for all user accounts on the computer. The command must run the command with administrator permissions.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: FalseThe Force parameter shuts down the version that is currently running so that it can update the application files.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: FalseUse this parameter to include prerelease versions of the WinGet client.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: IntegrityLatestSet
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: FalseUse this parameter to install the latest available version of the WinGet client.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: IntegrityLatestSet
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: FalseSpecifies the version of the WinGet client to install or repair. You can provide an exact version number or use wildcard characters (for example, "1.*.1*") to match and install the latest version that fits the pattern.
Type: System.String
Parameter Sets: IntegrityVersionSet
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: FalseThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.