.\"t .\" Automatically generated by Pandoc 2.1.3 .\" .TH "dotnet command \- .NET Core CLI" "1" "" "" ".NET Core" .hy .SH dotnet command .PP .SH NAME .PP \f[C]dotnet\f[] \- General driver for running the command\-line commands. .SH SYNOPSIS .SS .NET Core 2.x .IP .nf \f[C] dotnet\ [command]\ [arguments]\ [\-\-additional\-deps]\ [\-\-additionalprobingpath]\ [\-d|\-\-diagnostics] \ \ \ \ [\-\-fx\-version]\ [\-h|\-\-help]\ [\-\-info]\ [\-\-roll\-forward\-on\-no\-candidate\-fx]\ [\-v|\-\-verbosity]\ [\-\-version] \f[] .fi .SS .NET Core 1.x .IP .nf \f[C] dotnet\ [command]\ [arguments]\ [\-\-additionalprobingpath]\ [\-d|\-\-diagnostics]\ [\-\-fx\-version] \ \ \ \ [\-h|\-\-help]\ [\-\-info]\ [\-v|\-\-verbosity]\ [\-\-version] \f[] .fi .PP * * * * * .SH DESCRIPTION .PP \f[C]dotnet\f[] is a generic driver for the Command Line Interface (CLI) toolchain. Invoked on its own, it provides brief usage instructions. .PP Each specific feature is implemented as a command. In order to use the feature, the command is specified after \f[C]dotnet\f[], such as \f[C]dotnet\ build\f[]. All of the arguments following the command are its own arguments. .PP The only time \f[C]dotnet\f[] is used as a command on its own is to run framework\-dependent apps. Specify an application DLL after the \f[C]dotnet\f[] verb to execute the application (for example, \f[C]dotnet\ myapp.dll\f[]). .SH OPTIONS .SS .NET Core 2.x .PP \f[C]\-\-additional\-deps\ \f[] .PP Path to additional \f[I]deps.json\f[] file. .PP \f[C]\-\-additionalprobingpath\ \f[] .PP Path containing probing policy and assemblies to probe. .PP \f[C]\-d|\-\-diagnostics\f[] .PP Enables diagnostic output. .PP \f[C]\-\-fx\-version\ \f[] .PP Version of the installed .NET Core runtime to use to run the application. .PP \f[C]\-h|\-\-help\f[] .PP Prints out a short help for the command. If using with \f[C]dotnet\f[], it also prints a list of the available commands. .PP \f[C]\-\-info\f[] .PP Prints out detailed information about the CLI tooling and the environment, such as the current operating system, commit SHA for the version, and other information. .PP \f[C]\-\-roll\-forward\-on\-no\-candidate\-fx\f[] .PP Rolls forward on no candidate shared framework. .PP \f[C]\-v|\-\-verbosity\ \f[] .PP Sets the verbosity level of the command. Allowed values are \f[C]q[uiet]\f[], \f[C]m[inimal]\f[], \f[C]n[ormal]\f[], \f[C]d[etailed]\f[], and \f[C]diag[nostic]\f[]. Not supported in every command; see specific command page to determine if this option is available. .PP \f[C]\-\-version\f[] .PP Prints out the version of the .NET Core SDK in use. .SS .NET Core 1.x .PP \f[C]\-\-additionalprobingpath\ \f[] .PP Path containing probing policy and assemblies to probe. .PP \f[C]\-d|\-\-diagnostics\f[] .PP Enables diagnostic output. .PP \f[C]\-\-fx\-version\ \f[] .PP Version of the installed .NET Core runtime to use to run the application. .PP \f[C]\-h|\-\-help\f[] .PP Prints out a short help for the command. If using with \f[C]dotnet\f[], it also prints a list of the available commands. .PP \f[C]\-\-info\f[] .PP Prints out detailed information about the CLI tooling and the environment, such as the current operating system, commit SHA for the version, and other information. .PP \f[C]\-v|\-\-verbosity\ \f[] .PP Sets the verbosity level of the command. Allowed values are \f[C]q[uiet]\f[], \f[C]m[inimal]\f[], \f[C]n[ormal]\f[], \f[C]d[etailed]\f[], and \f[C]diag[nostic]\f[]. Not supported in every command; see specific command page to determine if this option is available. .PP \f[C]\-\-version\f[] .PP Prints out the version of the .NET Core SDK in use. .PP * * * * * .SS dotnet commands .SS General .SS .NET Core 2.x .PP .TS tab(@); l l. T{ Command T}@T{ Function T} _ T{ dotnet build T}@T{ Builds a .NET Core application. T} T{ dotnet clean T}@T{ Clean build outputs. T} T{ dotnet help T}@T{ Shows more detailed documentation online for the command. T} T{ dotnet migrate T}@T{ Migrates a valid Preview 2 project to a .NET Core SDK 1.0 project. T} T{ dotnet msbuild T}@T{ Provides access to the MSBuild command line. T} T{ dotnet new T}@T{ Initializes a C# or F# project for a given template. T} T{ dotnet pack T}@T{ Creates a NuGet package of your code. T} T{ dotnet publish T}@T{ Publishes a .NET framework\-dependent or self\-contained application. T} T{ dotnet restore T}@T{ Restores the dependencies for a given application. T} T{ dotnet run T}@T{ Runs the application from source. T} T{ dotnet sln T}@T{ Options to add, remove, and list projects in a solution file. T} T{ dotnet store T}@T{ Stores assemblies in the runtime package store. T} T{ dotnet test T}@T{ Runs tests using a test runner. T} .TE .SS .NET Core 1.x .PP .TS tab(@); l l. T{ Command T}@T{ Function T} _ T{ dotnet build T}@T{ Builds a .NET Core application. T} T{ dotnet clean T}@T{ Clean build outputs. T} T{ dotnet migrate T}@T{ Migrates a valid Preview 2 project to a .NET Core SDK 1.0 project. T} T{ dotnet msbuild T}@T{ Provides access to the MSBuild command line. T} T{ dotnet new T}@T{ Initializes a C# or F# project for a given template. T} T{ dotnet pack T}@T{ Creates a NuGet package of your code. T} T{ dotnet publish T}@T{ Publishes a .NET framework\-dependent or self\-contained application. T} T{ dotnet restore T}@T{ Restores the dependencies for a given application. T} T{ dotnet run T}@T{ Runs the application from source. T} T{ dotnet sln T}@T{ Options to add, remove, and list projects in a solution file. T} T{ dotnet test T}@T{ Runs tests using a test runner. T} .TE .PP * * * * * .SS Project references .PP .TS tab(@); l l. T{ Command T}@T{ Function T} _ T{ dotnet add reference T}@T{ Add a project reference. T} T{ dotnet list reference T}@T{ List project references. T} T{ dotnet remove reference T}@T{ Remove a project reference. T} .TE .SS NuGet packages .PP .TS tab(@); l l. T{ Command T}@T{ Function T} _ T{ dotnet add package T}@T{ Add a NuGet package. T} T{ dotnet remove package T}@T{ Remove a NuGet package. T} .TE .SS NuGet commands .PP .TS tab(@); l l. T{ Command T}@T{ Function T} _ T{ dotnet nuget delete T}@T{ Deletes or unlists a package from the server. T} T{ dotnet nuget locals T}@T{ Clears or lists local NuGet resources such as http\-request cache, temporary cache, or machine\-wide global packages folder. T} T{ dotnet nuget push T}@T{ Pushes a package to the server and publishes it. T} .TE .SH EXAMPLES .PP Initialize a sample .NET Core console application that can be compiled and run: .PP \f[C]dotnet\ new\ console\f[] .PP Restore dependencies for a given application: .PP \f[C]dotnet\ restore\f[] .PP .PP Build a project and its dependencies in a given directory: .PP \f[C]dotnet\ build\f[] .PP Run a framework\-dependent app named \f[C]myapp.dll\f[]: .PP \f[C]dotnet\ myapp.dll\f[] .SH ENVIRONMENT VARIABLES .SS .NET Core 2.x .PP \f[C]DOTNET_PACKAGES\f[] .PP The primary package cache. If not set, it defaults to \f[C]$HOME/.nuget/packages\f[] on Unix or \f[C]%HOME%\\NuGet\\Packages\f[] on Windows. .PP \f[C]DOTNET_SERVICING\f[] .PP Specifies the location of the servicing index to use by the shared host when loading the runtime. .PP \f[C]DOTNET_CLI_TELEMETRY_OPTOUT\f[] .PP Specifies whether data about the .NET Core tools usage is collected and sent to Microsoft. Set to \f[C]true\f[] to opt\-out of the telemetry feature (values \f[C]true\f[], \f[C]1\f[], or \f[C]yes\f[] accepted); otherwise, set to \f[C]false\f[] to opt\-in to the telemetry features (values \f[C]false\f[], \f[C]0\f[], or \f[C]no\f[] accepted). If not set, the defaults is \f[C]false\f[], and the telemetry feature is active. .PP \f[C]DOTNET_MULTILEVEL_LOOKUP\f[] .PP Specifies whether .NET Core runtime, shared framework or SDK are resolved from the global location. If not set, it defaults to \f[C]true\f[]. Set to \f[C]false\f[] to not resolve from the global location and have isolated .NET Core installations (values \f[C]0\f[] or \f[C]false\f[] are accepted). For more information about multi\-level lookup, see Multi\-level SharedFX Lookup. .SS .NET Core 1.x .PP \f[C]DOTNET_PACKAGES\f[] .PP The primary package cache. If not set, it defaults to \f[C]$HOME/.nuget/packages\f[] on Unix or \f[C]%HOME%\\NuGet\\Packages\f[] on Windows. .PP \f[C]DOTNET_SERVICING\f[] .PP Specifies the location of the servicing index to use by the shared host when loading the runtime. .PP \f[C]DOTNET_CLI_TELEMETRY_OPTOUT\f[] .PP Specifies whether data about the .NET Core tools usage is collected and sent to Microsoft. Set to \f[C]true\f[] to opt\-out of the telemetry feature (values \f[C]true\f[], \f[C]1\f[], or \f[C]yes\f[] accepted); otherwise, set to \f[C]false\f[] to opt\-in to the telemetry features (values \f[C]false\f[], \f[C]0\f[], or \f[C]no\f[] accepted). If not set, the defaults is \f[C]false\f[], and the telemetry feature is active. .PP * * * * * .SH AUTHORS mairaw.