mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-12 06:56:24 +00:00
docs(nuget): rewrite, add admonitions, add headings (#18906)
This commit is contained in:
parent
68a329f4bb
commit
79889a7ff3
1 changed files with 16 additions and 7 deletions
|
@ -59,19 +59,26 @@ You can set alternative feeds:
|
|||
|
||||
In the example above we've set three NuGet feeds.
|
||||
The package resolving process uses the `merge` strategy to handle the three feeds.
|
||||
All feeds are checked for dependency updates, and duplicate updates are merged/joined together into a single dependency update.
|
||||
All feeds are checked for dependency updates, and duplicate updates are merged into a single dependency update.
|
||||
|
||||
If your project uses lockfiles (a `package.lock.json` exists), alternate feed settings must be defined in a `NuGet.config` only, as `registryUrls` are not passed through to the NuGet commands used.
|
||||
<!-- prettier-ignore -->
|
||||
!!! warning
|
||||
If your project has lockfile(s), for example a `package.lock.json` file, then you must set alternate feed settings in the `NuGet.config` file only.
|
||||
`registryUrls` set in other files are **not** passed to the NuGet commands.
|
||||
|
||||
### Protocol versions
|
||||
|
||||
NuGet supports two protocol versions, `v2` and `v3`.
|
||||
The NuGet client and server must use the same version.
|
||||
When Renovate acts as the client, it can use the `v2` and `v3` protocols.
|
||||
|
||||
Renovate as a NuGet client supports both `v2` and `v3` protocols, and will use `v2` unless the configured feed URL ends with `index.json`.
|
||||
This mirrors the behavior of the official NuGet client.
|
||||
By default, Renovate uses the `v2` protocol.
|
||||
If the configured feed URL ends with `index.json`, Renovate uses the `v3` protocol.
|
||||
So Renovate behaves like the official NuGet client.
|
||||
|
||||
If you have a `v3` feed that doesn't end with `index.json`, like for example on the JFrog Artifactory, then you must append `#protocolVersion=3` to the registry URL:
|
||||
#### v3 feed URL not ending with index.json
|
||||
|
||||
If a `v3` feed URL does not end with `index.json`, you must append `#protocolVersion=3` to the registry URL:
|
||||
|
||||
```json
|
||||
{
|
||||
|
@ -81,6 +88,8 @@ If you have a `v3` feed that doesn't end with `index.json`, like for example on
|
|||
}
|
||||
```
|
||||
|
||||
You may need this workaround when you use the JFrog Artifactory.
|
||||
|
||||
## Authenticated feeds
|
||||
|
||||
Credentials for authenticated/private feeds can be given via host rules in the configuration options (file or command line parameter).
|
||||
|
@ -98,12 +107,12 @@ Credentials for authenticated/private feeds can be given via host rules in the c
|
|||
}
|
||||
```
|
||||
|
||||
When using Azure DevOps, you can use `pkgs.dev.azure.com` as `matchHost` value.
|
||||
If you're using Azure DevOps, you can set `matchHost` to `pkgs.dev.azure.com`.
|
||||
|
||||
<!-- prettier-ignore -->
|
||||
!!! note
|
||||
Only Basic HTTP authentication (via username and password) is supported.
|
||||
For Azure DevOps, you can use a Personal Access Token (PAT) with read permissions on `Packaging` along with an empty username.
|
||||
For Azure DevOps, you can use a PAT with `read` permissions on `Packaging` plus an empty username.
|
||||
|
||||
## Future work
|
||||
|
||||
|
|
Loading…
Reference in a new issue