-
Notifications
You must be signed in to change notification settings - Fork 6k
Update and clean up dotnet.md #17183
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor things to fix/look at. Looks good.
@wli3 please review |
Co-Authored-By: Maira Wenzel <mairaw@microsoft.com>
@vitek-karas could you review this doc? It is mostly about runtime features |
From SDK perspective this is good. Although most of them are not SDK features |
docs/core/tools/dotnet.md
Outdated
``` | ||
|
||
# [.NET Core 1.x](#tab/netcore1x) | ||
To run an application (.NET Core 2.x SDK): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not SDK specific - this works even without installed SDK.
docs/core/tools/dotnet.md
Outdated
``` | ||
|
||
# [.NET Core 2.0](#tab/netcore20) | ||
To run a command: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one basically requires SDK - the only command which works without SDK is dotnet exec
which is special - and probably can be added to the case below (as it runs an app).
docs/core/tools/dotnet.md
Outdated
For more information, see [Roll forward](../whats-new/dotnet-core-2-1.md#roll-forward). | ||
|
||
`--runtimeconfig` | ||
To run an application (.NET Core SDK 3.x): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as above - not SDK specific.
docs/core/tools/dotnet.md
Outdated
|
||
`--version` | ||
- It manages .NET Core source code and binaries. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would not say "manage" that sounds like dotnet
is the only way to work with the source code and/or binaries. For example VS/VSCode will handle the source code as well... and running the app is possible with the generated executable instead of dotnet
(in fact it's the preferred way for 3.0 and above).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe something like "It provides command to work with .NET Core projects"....
docs/core/tools/dotnet.md
Outdated
|
||
Path containing probing policy and assemblies to probe. | ||
### SDK options for dotnet by itself |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not SDK specific - these commands work always, even if SDK is not installed.
docs/core/tools/dotnet.md
Outdated
|
||
Version of the .NET Core runtime to use to run the application. | ||
Print out a list of the installed .NET Core runtimes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Print out a list of the installed .NET Core runtimes. | |
Prints out a list of the installed .NET Core runtimes. |
docs/core/tools/dotnet.md
Outdated
|
||
Specifies whether data about the .NET Core tools usage is collected and sent to Microsoft. Set to `true` to opt-out of the telemetry feature (values `true`, `1`, or `yes` accepted). Otherwise, set to `false` to opt into the telemetry features (values `false`, `0`, or `no` accepted). If not set, the default is `false` and the telemetry feature is active. | ||
Specifies the location of the .NET Core SDK and runtimes if they are not installed in the default location. The default location on Windows is `C:\Program Files\dotnet`. The default location on Linux and macOS is `/usr/share/dotnet`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SDK is optional - so I would word it something like "the location of the .NET Core runtimes and optionally SDKs if they..."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In fact DOTNET_ROOT
is only used for running apps via generated executables (apphosts), the muxer dotnet.exe
ignores this env. variable. So it really only applies to running apps through executables - has no effect on SDK lookup and dotnet.exe
itself`.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's also DOTNET_ROOT(x86)
which is used on 64bit OS when running 32bit executable (instead of DOTNET_ROOT
which is the 64bit version that case).
docs/core/tools/dotnet.md
Outdated
|
||
`DOTNET_SERVICING` | ||
Specifies whether .NET Core runtime, shared framework, or SDK are resolved from the global location. If not set, it defaults to `true`. Set to `false` to not resolve from the global location and have isolated .NET Core installations (values `0` or `false` are accepted). For more information about multi-level lookup, see [Multi-level SharedFX Lookup](https://github.com/dotnet/core-setup/blob/master/Documentation/design-docs/multilevel-sharedfx-lookup.md). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The allowed values are 0
(logical false) and 1
(logical true).
Specifies whether data about the .NET Core tools usage is collected and sent to Microsoft. Set to `true` to opt-out of the telemetry feature (values `true`, `1`, or `yes` accepted). Otherwise, set to `false` to opt into the telemetry features (values `false`, `0`, or `no` accepted). If not set, the default is `false` and the telemetry feature is active. | ||
|
||
--- | ||
Sets the language of the CLI UI using a locale value such as `en-us`. The supported values are the same as for Visual Studio. For more information, see the section on changing the installer language in the [Visual Studio installation documentation](https://docs.microsoft.com/visualstudio/install/install-visual-studio?view=vs-2019). The .NET resource manager rules apply, so you don't have to pick an exact match—you can also pick descendants in the `CultureInfo` tree. For example, if you set it to `fr-CA`, the CLI will find and use the `fr` translations. If you set it to a language that is not supported, the CLI falls back to English. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are other env. variables supported by dotnet.exe
(and the generated executables). Not sure if we should include them all, but for completeness:
DOTNET_DISABLE_GUI_ERRORS
- for GUI enabled generated executables - disables dialog popup which normally shows for certain class of errors (only writes to stderr and exits in that case).DOTNET_ADDITIONAL_DEPS
- basically env. variable version of--additional-deps
.DOTNET_RUNTIME_ID
- override the detected RIDDOTNET_SHARED_STORE
- location of the "shared store" where assembly resolution falls back to in some casesDOTNET_STARTUP_HOOKS
- list of assemblies to load and execute startup hooks fromCOREHOST_TRACE
,COREHOST_TRACEFILE
,COREHOST_TRACE_VERBOSITY
- controls diagnostics tracing from the hosting components (dotnet.exe
,hostfxr
,hostpolicy
, ...).
@wli3 and @vitek-karas Thanks for reviewing! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Fixes #14122
Fixes #9893
Fixes #8988
Internal review URL