< Back

Register-ChocolateySource

Mon Jan 13, 2020 1:38 am

NAME Register-ChocolateySource



SYNOPSIS

Register a new Chocolatey source or edit an existing one.





SYNTAX

Register-ChocolateySource [-Name] <String> [-Source] <Object> [-Disabled] [-BypassProxy] [-SelfService]

[[-Priority] <Int32>] [[-Credential] <PSCredential>] [-Force] [[-CacheLocation] <String>] [-NoProgress]

[[-KeyUser] <Object>] [[-Key] <Object>] [<CommonParameters>]





DESCRIPTION

Chocolatey will allow you to interact with sources.

You can register a new source, whether internal or external with some source

specific settings such as proxy.





PARAMETERS

-Name <String>

Name - the name of the source. Required with some actions. Defaults to empty.



Required? true

Position? 1

Default value

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-Source <Object>

Source - The source. This can be a folder/file share or an http location.

If it is a url, it will be a location you can go to in a browser and

it returns OData with something that says Packages in the browser,

similar to what you see when you go to https://chocolatey.org/api/v2/.

Defaults to empty.



Required? true

Position? 2

Default value

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-Disabled [<SwitchParameter>]

Allow the source to be registered but disabled.



Required? false

Position? named

Default value False

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-BypassProxy [<SwitchParameter>]

Bypass Proxy - Should this source explicitly bypass any explicitly or

system configured proxies? Defaults to false. Available in 0.10.4+.



Required? false

Position? named

Default value False

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-SelfService [<SwitchParameter>]

Allow Self-Service - Should this source be allowed to be used with self-

service? Requires business edition (v1.10.0+) with feature

'useBackgroundServiceWithSelfServiceSourcesOnly' turned on. Defaults to

false. Available in 0.10.4+.



Required? false

Position? named

Default value False

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-Priority <Int32>

Priority - The priority order of this source as compared to other

sources, lower is better. Defaults to 0 (no priority). All priorities

above 0 will be evaluated first, then zero-based values will be

evaluated in config file order. Available in 0.9.9.9+.



Required? false

Position? 3

Default value 0

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-Credential <PSCredential>

Credential used with authenticated feeds. Defaults to empty.



Required? false

Position? 4

Default value

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-Force [<SwitchParameter>]

Force - force the behavior. Do not use force during normal operation -

it subverts some of the smart behavior for commands.



Required? false

Position? named

Default value False

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-CacheLocation <String>

CacheLocation - Location for download cache, defaults to %TEMP% or value

in chocolatey.config file.



Required? false

Position? 5

Default value

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-NoProgress [<SwitchParameter>]

Do Not Show Progress - Do not show download progress percentages.

Available in 0.10.4+.



Required? false

Position? named

Default value False

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-KeyUser <Object>

API Key User for the source being registered.



Required? false

Position? 6

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Key <Object>

API key for the source (too long in C4B to be passed as credentials)



Required? false

Position? 7

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



NOTES





https://github.com/chocolatey/choco/wiki/CommandsSource



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Register-ChocolateySource -Name MyNuget -Source https://proget/nuget/choco















RELATED LINKS