Skip to content

Commit b92c74f

Browse files
committed
Specify .NET 6 SDK as minimum version and update options
1 parent 65ccc2d commit b92c74f

13 files changed

+129
-122
lines changed

docs/core/tools/dotnet-build.md

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/24/2025
55
---
66
# dotnet build
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

@@ -16,15 +16,13 @@ ms.date: 09/24/2025
1616
```dotnetcli
1717
dotnet build [<PROJECT>|<SOLUTION>|<FILE>] [-a|--arch <ARCHITECTURE>]
1818
[--artifacts-path <ARTIFACTS_DIR>]
19-
[-c|--configuration <CONFIGURATION>] [-f|--framework <FRAMEWORK>]
20-
[--disable-build-servers]
21-
[--force] [--interactive] [--no-dependencies] [--no-incremental]
22-
[--no-restore] [--nologo] [--no-self-contained] [--os <OS>]
23-
[-o|--output <OUTPUT_DIRECTORY>]
24-
[-p|--property:<PROPERTYNAME>=<VALUE>]
25-
[-r|--runtime <RUNTIME_IDENTIFIER>]
26-
[-sc|--self-contained [true|false]] [--source <SOURCE>]
27-
[--tl:[auto|on|off]] [--use-current-runtime, --ucr [true|false]]
19+
[-c|--configuration <CONFIGURATION>] [--disable-build-servers]
20+
[-f|--framework <FRAMEWORK>] [--force] [--interactive]
21+
[--no-dependencies] [--no-incremental] [--no-restore] [--nologo]
22+
[--no-self-contained] [-o|--output <OUTPUT_DIRECTORY>] [--os <OS>]
23+
[-p|--property:<PROPERTYNAME>=<VALUE>] [-r|--runtime <RUNTIME_IDENTIFIER>]
24+
[--sc|--self-contained] [--source <SOURCE>]
25+
[--tl:[auto|on|off]] [ --ucr|--use-current-runtime]
2826
[-v|--verbosity <LEVEL>] [--version-suffix <VERSION_SUFFIX>]
2927
3028
dotnet build -h|--help
@@ -95,8 +93,6 @@ Running `dotnet build` is equivalent to running `dotnet msbuild -restore`; howev
9593

9694
Forces all dependencies to be resolved even if the last restore was successful. Specifying this flag is the same as deleting the *project.assets.json* file.
9795

98-
[!INCLUDE [help](../../../includes/cli-help.md)]
99-
10096
[!INCLUDE [interactive](../../../includes/cli-interactive-3-0.md)]
10197

10298
- **`--no-dependencies`**
@@ -142,28 +138,30 @@ Running `dotnet build` is equivalent to running `dotnet msbuild -restore`; howev
142138

143139
Specifies the target runtime. For a list of Runtime Identifiers (RIDs), see the [RID catalog](../rid-catalog.md). If you use this option with .NET 6 SDK, use `--self-contained` or `--no-self-contained` also. If not specified, the default is to build for the current OS and architecture.
144140

145-
- **`--self-contained [true|false]`**
141+
- **`--sc|--self-contained`**
146142

147-
Publishes the .NET runtime with the application so the runtime doesn't need to be installed on the target machine. The default is `true` if a runtime identifier is specified. Available since .NET 6.
143+
Publishes the .NET runtime with the application so the runtime doesn't need to be installed on the target machine. The default is `false`. However, when targeting .NET 7 or lower, the default is `true` if a runtime identifier is specified. Available since .NET 6 SDK.
148144

149145
- **`--source <SOURCE>`**
150146

151147
The URI of the NuGet package source to use during the restore operation.
152148

153149
[!INCLUDE [tl](../../../includes/cli-tl.md)]
154150

155-
- **`-v|--verbosity <LEVEL>`**
151+
- **`--ucr|--use-current-runtime`**
156152

157-
Sets the verbosity level of the command. Allowed values are `q[uiet]`, `m[inimal]`, `n[ormal]`, `d[etailed]`, and `diag[nostic]`. The default is `minimal`. By default, MSBuild displays warnings and errors at all verbosity levels. To exclude warnings, use `/property:WarningLevel=0`. For more information, see <xref:Microsoft.Build.Framework.LoggerVerbosity> and [WarningLevel](../../csharp/language-reference/compiler-options/errors-warnings.md#warninglevel).
153+
Use current runtime as the target runtime. The default is `false`.
158154

159-
- **`--use-current-runtime, --ucr [true|false]`**
155+
- **`-v|--verbosity <LEVEL>`**
160156

161-
Sets the `RuntimeIdentifier` to a platform portable `RuntimeIdentifier` based on the one of your machine. This happens implicitly with properties that require a `RuntimeIdentifier`, such as `SelfContained`, `PublishAot`, `PublishSelfContained`, `PublishSingleFile`, and `PublishReadyToRun`. If the property is set to false, that implicit resolution will no longer occur.
157+
Sets the verbosity level of the command. Allowed values are `q[uiet]`, `m[inimal]`, `n[ormal]`, `d[etailed]`, and `diag[nostic]`. The default is `minimal`. By default, MSBuild displays warnings and errors at all verbosity levels. To exclude warnings, use `/property:WarningLevel=0`. For more information, see <xref:Microsoft.Build.Framework.LoggerVerbosity> and [WarningLevel](../../csharp/language-reference/compiler-options/errors-warnings.md#warninglevel).
162158

163159
- **`--version-suffix <VERSION_SUFFIX>`**
164160

165161
Sets the value of the `$(VersionSuffix)` property to use when building the project. This only works if the `$(Version)` property isn't set. Then, `$(Version)` is set to the `$(VersionPrefix)` combined with the `$(VersionSuffix)`, separated by a dash.
166162

163+
[!INCLUDE [help](../../../includes/cli-help.md)]
164+
167165
## Examples
168166

169167
- Build a project and its dependencies:

docs/core/tools/dotnet-clean.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/24/2025
55
---
66
# dotnet clean
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

docs/core/tools/dotnet-dev-certs.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/29/2025
55
---
66
# dotnet dev-certs
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

@@ -15,10 +15,11 @@ ms.date: 09/29/2025
1515

1616
```dotnetcli
1717
dotnet dev-certs https
18-
[-c|--check] [--clean] [-ep|--export-path <PATH>]
18+
[-c|--check] [--check-trust-machine-readable]
19+
[--clean] [-ep|--export-path <PATH>]
1920
[--format] [-i|--import] [-np|--no-password]
2021
[-p|--password] [-q|--quiet] [-t|--trust]
21-
[-v|--verbose] [--version] [--check-trust-machine-readable]
22+
[-v|--verbose] [--version]
2223
2324
dotnet dev-certs https -h|--help
2425
```
@@ -61,6 +62,10 @@ The `dotnet dev-certs` command manages a self-signed certificate to enable HTTPS
6162

6263
Checks for the existence of the development certificate but doesn't perform any action. Use this option with the `--trust` option to check if the certificate is not only valid but also trusted.
6364

65+
- **`--check-trust-machine-readable`**
66+
67+
Same as running `--check --trust`, but outputs the results in json.
68+
6469
- **`--clean`**
6570

6671
Removes all HTTPS development certificates from the certificate store by using the .NET certificate store API. Doesn't remove any physical files that were created by using the `--export-path` option. On macOS in .NET 7.0, the `dotnet dev-certs` command creates the certificate on a path on disk, and the clean operation removes that certificate file.
@@ -140,10 +145,6 @@ The `dotnet dev-certs` command manages a self-signed certificate to enable HTTPS
140145

141146
Display debug information.
142147

143-
- **`--check-trust-machine-readable`**
144-
145-
Same as running `--check --trust`, but outputs the results in json.
146-
147148
## Examples
148149

149150
- Check for the presence of a development certificate, and create one in the default certificate store if one doesn't exist yet. But don't trust the certificate.

docs/core/tools/dotnet-format.md

Lines changed: 28 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/29/2025
55
---
66
# dotnet format
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

@@ -15,7 +15,11 @@ ms.date: 09/29/2025
1515

1616
```dotnetcli
1717
dotnet format [<PROJECT | SOLUTION>]
18-
[--diagnostics <DIAGNOSTICS>] [--exclude-diagnostics <EXCLUDE-DIAGNOSTICS>] [--severity <SEVERITY>] [--no-restore] [--verify-no-changes] [--include <INCLUDE>] [--exclude <EXCLUDE>] [--include-generated] [-v|--verbosity <LEVEL>] [--binarylog <BINARY-LOG-PATH>] [--report <REPORT-PATH>] [--version]
18+
[--binarylog <BINARY-LOG-PATH>] [--diagnostics <DIAGNOSTICS>]
19+
[--exclude <EXCLUDE>] [--exclude-diagnostics <EXCLUDE-DIAGNOSTICS>]
20+
[--include <INCLUDE>] [--include-generated]
21+
[--no-restore] [--report <REPORT-PATH>] [--severity <SEVERITY>]
22+
[-v|--verbosity <LEVEL>] [--verify-no-changes] [--version]
1923
2024
dotnet format -h|--help
2125
```
@@ -34,54 +38,54 @@ The MSBuild project or solution to run code formatting on. If a project or solut
3438

3539
None of the options below are required for the `dotnet format` command to succeed, but you can use them to further customize what is formatted and by which rules.
3640

37-
- **`--diagnostics <DIAGNOSTICS>`**
38-
39-
A space-separated list of diagnostic IDs to use as a filter when fixing code style or third-party issues. Default value is whichever IDs are listed in the *.editorconfig* file. For a list of built-in analyzer rule IDs that you can specify, see the [list of IDs for code-analysis style rules](../../fundamentals/code-analysis/style-rules/index.md).
40-
41-
- **`--exclude-diagnostics <EXCLUDE-DIAGNOSTICS>`**
41+
- **`--binarylog <BINARY-LOG-PATH>`**
4242

43-
A space-separated list of diagnostic IDs to exclude when fixing code style or third-party issues. Default value is none. For a list of built-in analyzer rule IDs that you can specify, see the [list of IDs for code-analysis style rules](../../fundamentals/code-analysis/style-rules/index.md).
43+
Logs all project or solution load information to a binary log file.
4444

45-
- **`--severity`**
45+
- **`--diagnostics <DIAGNOSTICS>`**
4646

47-
The minimum severity of diagnostics to fix. Allowed values are `info`, `warn`, and `error`. The default value is `warn`.
47+
A space-separated list of diagnostic IDs to use as a filter when fixing code style or third-party issues. Default value is whichever IDs are listed in the *.editorconfig* file. For a list of built-in analyzer rule IDs that you can specify, see the [list of IDs for code-analysis style rules](../../fundamentals/code-analysis/style-rules/index.md).
4848

49-
- **`--no-restore`**
49+
- **`--exclude <EXCLUDE>`**
5050

51-
Doesn't execute an implicit restore before formatting. Default is to do implicit restore.
51+
A space-separated list of relative file or folder paths to exclude from formatting. The default is none.
5252

53-
- **`--verify-no-changes`**
53+
- **`--exclude-diagnostics <EXCLUDE-DIAGNOSTICS>`**
5454

55-
Verifies that no formatting changes would be performed. Terminates with a non zero exit code if any files would have been formatted.
55+
A space-separated list of diagnostic IDs to exclude when fixing code style or third-party issues. Default value is none. For a list of built-in analyzer rule IDs that you can specify, see the [list of IDs for code-analysis style rules](../../fundamentals/code-analysis/style-rules/index.md).
5656

5757
- **`--include <INCLUDE>`**
5858

5959
A space-separated list of relative file or folder paths to include in formatting. The default is all files in the solution or project.
6060

61-
- **`--exclude <EXCLUDE>`**
62-
63-
A space-separated list of relative file or folder paths to exclude from formatting. The default is none.
64-
6561
- **`--include-generated`**
6662

6763
Formats files generated by the SDK.
6864

69-
- **`-v|--verbosity <LEVEL>`**
70-
71-
Sets the verbosity level. Allowed values are `q[uiet]`, `m[inimal]`, `n[ormal]`, `d[etailed]`, and `diag[nostic]`. Default value is `m[inimal]`.
72-
73-
- **`--binarylog <BINARY-LOG-PATH>`**
65+
- **`--no-restore`**
7466

75-
Logs all project or solution load information to a binary log file.
67+
Doesn't execute an implicit restore before formatting. Default is to do implicit restore.
7668

7769
- **`--report <REPORT-PATH>`**
7870

7971
Produces a JSON report in the directory specified by `<REPORT_PATH>`.
8072

73+
- **`--severity`**
74+
75+
The minimum severity of diagnostics to fix. Allowed values are `info`, `warn`, and `error`. The default value is `warn`.
76+
77+
- **`--verify-no-changes`**
78+
79+
Verifies that no formatting changes would be performed. Terminates with a non zero exit code if any files would have been formatted.
80+
8181
- **`--version`**
8282

8383
Displays version information.
8484

85+
- **`-v|--verbosity <LEVEL>`**
86+
87+
Sets the verbosity level. Allowed values are `q[uiet]`, `m[inimal]`, `n[ormal]`, `d[etailed]`, and `diag[nostic]`. Default value is `m[inimal]`.
88+
8589
[!INCLUDE [help](../../../includes/cli-help.md)]
8690

8791
## Subcommands

docs/core/tools/dotnet-msbuild.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/29/2025
55
---
66
# dotnet msbuild
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

docs/core/tools/dotnet-pack.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/29/2025
55
---
66
# dotnet pack
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

@@ -15,8 +15,11 @@ ms.date: 09/29/2025
1515

1616
```dotnetcli
1717
dotnet pack [<PROJECT>|<SOLUTION>]
18-
[--artifacts-path <ARTIFACTS_DIR>]
19-
[-c|--configuration <CONFIGURATION>] [--disable-build-servers][--force] [--include-source] [--include-symbols] [--interactive] [--no-build] [--no-dependencies] [--no-restore] [--nologo] [-o|--output <OUTPUT_DIRECTORY>] [--runtime <RUNTIME_IDENTIFIER>] [-s|--serviceable] [--tl:[auto|on|off]] [-v|--verbosity <LEVEL>]
18+
[--artifacts-path <ARTIFACTS_DIR>] [-c|--configuration <CONFIGURATION>]
19+
[--disable-build-servers] [--force] [--include-source] [--include-symbols]
20+
[--interactive] [--no-build] [--no-dependencies] [--no-restore] [--nologo]
21+
[-o|--output <OUTPUT_DIRECTORY>] [--runtime <RUNTIME_IDENTIFIER>]
22+
[-s|--serviceable] [--tl:[auto|on|off]] [-v|--verbosity <LEVEL>]
2023
[--version-suffix <VERSION_SUFFIX>]
2124
2225
dotnet pack -h|--help
@@ -67,8 +70,6 @@ You can provide MSBuild properties to the `dotnet pack` command for the packing
6770

6871
Forces all dependencies to be resolved even if the last restore was successful. Specifying this flag is the same as deleting the *project.assets.json* file.
6972

70-
[!INCLUDE [help](../../../includes/cli-help.md)]
71-
7273
- **`--include-source`**
7374

7475
Includes the debug symbols NuGet packages in addition to the regular NuGet packages in the output directory. The sources files are included in the `src` folder within the symbols package.
@@ -131,6 +132,8 @@ You can provide MSBuild properties to the `dotnet pack` command for the packing
131132

132133
If `Version` has a value and you pass `--version-suffix` to `dotnet pack`, the value specified for `--version-suffix` is ignored.
133134

135+
[!INCLUDE [help](../../../includes/cli-help.md)]
136+
134137
## Examples
135138

136139
- Pack the project in the current directory:

docs/core/tools/dotnet-package-remove.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: 09/29/2025
55
---
66
# dotnet package remove
77

8-
**This article applies to:** ✔️ .NET 6 and later versions
8+
**This article applies to:** ✔️ .NET 6 SDK and later versions
99

1010
## Name
1111

@@ -17,8 +17,8 @@ ms.date: 09/29/2025
1717
## Synopsis
1818

1919
```dotnetcli
20-
dotnet package remove <PACKAGE_NAME> [--project <PROJECT>]
21-
[--interactive] [--file <FILE>]
20+
dotnet package remove <PACKAGE_NAME>
21+
[--file <FILE>] [--interactive] [--project <PROJECT>]
2222
2323
dotnet package remove -h|--help
2424
```
@@ -35,15 +35,15 @@ The package reference to remove.
3535

3636
## Options
3737

38-
- **`-p|--project <PROJECT>`**
38+
- **`--file <FILE>`**
3939

40-
The project file to operate on. If a solution file is specified, the command will update the package in all projects in the solution that reference it. If not specified, the command will search the current directory for a project file.
40+
The file-based app to operate on.
4141

4242
[!INCLUDE [interactive](../../../includes/cli-interactive.md)]
4343

44-
- **`--file <FILE>`**
44+
- **`-p|--project <PROJECT>`**
4545

46-
The file-based app to operate on.
46+
The project file to operate on. If a solution file is specified, the command will update the package in all projects in the solution that reference it. If not specified, the command will search the current directory for a project file.
4747

4848
[!INCLUDE [help](../../../includes/cli-help.md)]
4949

0 commit comments

Comments
 (0)