Unregister-PSRepository
Syntax
Unregister-PSRepository
[-Name] <String[]>
[<CommonParameters>]
Description
The Unregister-PSRepository cmdlet unregisters a repository for the current user.
Examples
Example 1: Unregister a repository
PS C:\> Unregister-PSRepository -Name "myNuGetSource"
This command unregisters the repository named myNuGetSource.
Example 2: Unregister all repositories
PS C:\> Get-PSRepository | Unregister-PSRepository
This command uses Get-PSRepository to get all registered repositories, and uses the pipeline operator to pass them to Unregister-PSRepository to unregister them. Note that PSGallery is a built-in repository and cannot be unregistered.
Required Parameters
Specifies an array of names of the repositories to remove.
Type: | String[] |
Position: | 1 |
Default value: | None |
Accept pipeline input: | True (ByPropertyName) |
Accept wildcard characters: | False |