Paket


paket config

Store global configuration values like NuGet credentials.

 1: 
 2: 
 3: 
 4: 
 5: 
 6: 
 7: 
 8: 
 9: 
10: 
11: 
12: 
13: 
14: 
15: 
16: 
17: 
18: 
paket config [--help] [add-credentials <key or URL>] [add-token <key or URL> <token>]
             [--username <username>] [--password <password>] [--authtype <authType>] [--verify]

OPTIONS:

    add-credentials <key or URL>
                          add credentials for URL or credential key
    add-token <key or URL> <token>
                          add token for URL or credential key
    --username <username> provide username
    --password <password> provide password
    --authtype <authType> specify authentication type: basic|ntlm (default: basic)
    --verify              specify in case you want to verify the credentials
    --silent, -s          suppress console output
    --verbose, -v         print detailed information to the console
    --log-file <path>     print output to a file
    --from-bootstrapper   call coming from the '--run' feature of the bootstrapper
    --help                display this list of options.

If you add the --verbose flag Paket will run in verbose mode and show detailed information.

With --log-file [path] you can trace the logged information into a file.

Adding credentials

URL credentials

1: 
paket config add-credentials <source URL>

Paket will then ask you for the username, password, and authentication type that will be used for the specified <source URL>.

The credentials you enter here will then be used for sources in the paket.dependencies file that match <source URL> unless they carry a username and password.

Verifying the source URL and credentials

1: 
paket config add-credentials <source URL> --verify

Paket will verify that the <source URL> and the credentials entered with the given authentication type are valid. This feature is useful if you want to avoid storing wrong credentials or URL in the Paket configuration file.

GitHub credentials

1: 
paket config add-credentials <credential key>

Paket will then ask you for the username and password that will be used for the specified <credential key>.

The credentials you enter here will then be used to access any GitHub files from the paket.dependencies file that carry the specified <credential key>.

1: 
paket config addtoken <credential key> <token>

The <token> you enter here will then be used to access any GitHub files from the paket.dependencies file that carry the specified <credential key>.

The configuration file can be found at:

1: 
2: 
3: 
let AppDataFolder = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)
let PaketConfigFolder = Path.Combine(AppDataFolder, "Paket")
let PaketConfigFile = Path.Combine(PaketConfigFolder, "paket.config")

Example

Adding a NuGet API key

1: 
paket config add-token 'https://www.nuget.org' '4003d786-cc37-4004-bfdf-c4f3deadbeef'
Fork me on GitHub