Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions docs/core/rid-catalog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: .NET Runtime Identifier (RID) catalog
description: Learn about the Runtime Identifier (RID) and how RIDs are used in .NET.
ms.date: 05/18/2022
ms.date: 07/11/2022
ms.topic: reference
---
# .NET RID Catalog
Expand All @@ -10,7 +10,7 @@ RID is short for *Runtime Identifier*. RID values are used to identify target pl
They're used by .NET packages to represent platform-specific assets in NuGet packages. The following values are examples of RIDs: `linux-x64`, `ubuntu.14.04-x64`, `win7-x64`, or `osx.10.12-x64`.
For the packages with native dependencies, the RID designates on which platforms the package can be restored.

A single RID can be set in the `<RuntimeIdentifier>` element of your project file. Multiple RIDs can be defined as a semicolon-delimited list in the project file's `<RuntimeIdentifiers>` element. They're also used via the `--runtime` option with the following [.NET CLI commands](./tools/index.md):
A single RID can be set in the [`<RuntimeIdentifier>`](project-sdk/msbuild-props.md#runtimeidentifier) element of your project file. Multiple RIDs can be defined as a semicolon-delimited list in the project file's [`<RuntimeIdentifiers>`](project-sdk/msbuild-props.md#runtimeidentifiers) element. They're also used via the `--runtime` option with the following [.NET CLI commands](./tools/index.md):

- [dotnet build](./tools/dotnet-build.md)
- [dotnet clean](./tools/dotnet-clean.md)
Expand All @@ -26,7 +26,7 @@ RIDs that represent concrete operating systems usually follow this pattern: `[os

- `[version]` is the operating system version in the form of a dot-separated (`.`) version number. For example, `15.10`.

- The version **shouldn't** be marketing versions, as they often represent multiple discrete versions of the operating system with varying platform API surface area.
The version **shouldn't** be a marketing version, as marketing versions often represent multiple discrete versions of the operating system with varying platform API surface area.

- `[architecture]` is the processor architecture. For example: `x86`, `x64`, `arm`, or `arm64`.

Expand Down Expand Up @@ -68,9 +68,11 @@ All RIDs eventually map back to the root `any` RID.
There are some considerations about RIDs that you have to keep in mind when working with them:

- Don't try to parse RIDs to retrieve component parts.
- Don't build RIDs programmatically.
- Use RIDs that are already defined for the platform.
- The RIDs need to be specific, so don't assume anything from the actual RID value.
- Don't build RIDs programmatically unless absolutely necessary.

Some apps need to compute RIDs programmatically. If so, the computed RIDs must match the catalog exactly, including in casing. RIDs with different casing would cause problems when the OS is case sensitive, for example, Linux, because the value is often used when constructing things like output paths. For example, consider a custom publishing wizard in Visual Studio that relies on information from the solution configuration manager and project properties. If the solution configuration passes an invalid value, for example, `ARM64` instead of `arm64`, it could result in an invalid RID, such as `win-ARM64`.

## Using RIDs

Expand Down