Skip to content

Commit 218dfe1

Browse files
authored
Reviewed the CLI topic (#1124)
* Reviewed the CLI topic * added version * undoing a small change
1 parent 21063bb commit 218dfe1

File tree

1 file changed

+35
-40
lines changed

1 file changed

+35
-40
lines changed

docs/core/tools/index.md

Lines changed: 35 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
11
---
2-
title: .NET Core Command Line Tools (CLI)
3-
description: .NET Core Command Line Tools (CLI)
4-
keywords: .NET, .NET Core
2+
title: .NET Core Command-Line Interface (CLI) Tools
3+
description: An overview of what the Command-Line Interface (CLI) is and its main features
4+
keywords: CLI, CLI tools, .NET, .NET Core
55
author: mairaw
66
manager: wpickett
7-
ms.date: 06/20/2016
7+
ms.date: 10/06/2016
88
ms.topic: article
99
ms.prod: .net-core
1010
ms.technology: .net-core-technologies
1111
ms.devlang: dotnet
1212
ms.assetid: b70e9ac0-c8be-49f7-9332-95ab93e0e7bc
1313
---
1414

15-
# .NET Core Command Line Tools
15+
# .NET Core Command-Line Interface Tools
1616

17-
## What is the .NET Core Command Line Interface (CLI)?
18-
The .NET Core CLI is a new foundational cross-platform toolchain for developing
17+
By [Zlatko Knezevic](https://github.com/blackdwarf) and [Maira Wenzel](https://github.com/mairaw)
18+
19+
The .NET Core Command-Line Interface (CLI) is a new foundational cross-platform toolchain for developing
1920
.NET Core applications. It is "foundational" because it is the primary layer on which other,
2021
higher-level tools, such as Integrated Development Environments (IDEs), editors and
2122
build orchestrators can build on.
@@ -38,11 +39,11 @@ prerequisites on the machine; you need to install all of the prerequisites manua
3839
setting up build servers or when you wish to install the tools without administrative privileges (do note the prerequisites
3940
caveat above). You can find more information on the [install script reference topic](dotnet-install-script.md). If you are
4041
interested in how to set up CLI on your continuous integration (CI) build server you can take a look at the
41-
[CLI with CI servers](using-ci-with-cli.md) document.
42+
[CLI with CI servers](using-ci-with-cli.md) topic.
4243

4344
By default, the CLI will install in a side-by-side (SxS) manner. This means that multiple versions of the CLI tools
4445
can coexist at any given time on a single machine. How the correct version gets used is explained in more detail in
45-
the [driver section](#driver) below.
46+
the [driver](#driver) section.
4647

4748
### What commands come in the box?
4849
The following commands are installed by default:
@@ -60,9 +61,8 @@ explained in greater detail in the [extensibility section](#extensibility).
6061

6162
## Working with the CLI
6263

63-
### A short sample
6464
Before we go into any more details, let's see how working with the CLI looks like from a 10,000-foot view.
65-
The sample below utilizes several commands from the CLI standard install to initialize a new simple console application,
65+
The following example utilizes several commands from the CLI standard install to initialize a new simple console application,
6666
restore the dependencies, build the application and then run it.
6767

6868
```console
@@ -72,64 +72,59 @@ dotnet build --output /stuff
7272
dotnet /stuff/new.dll
7373
```
7474

75-
### How does it work?
76-
As we saw in the short sample [above](#a-short-sample), there is a pattern in the way you use the CLI tools. Within that pattern, we can
75+
As you can see in the previous example, there is a pattern in the way you use the CLI tools. Within that pattern, we can
7776
identify three main pieces of each command:
7877

79-
1. The driver ("dotnet")
80-
2. The command, or "verb"
81-
3. Command arguments
82-
83-
Let's dig into more details on each of the above.
78+
1. [The driver ("dotnet")](#driver)
79+
2. [The command, or "verb"](#the-verb)
80+
3. [Command arguments](#the-arguments)
8481

8582
### Driver
86-
The driver is named `dotnet`. It is the first part of what you invoke. The driver has two responsibilities:
83+
The driver is named [dotnet](dotnet.md). It is the first part of what you invoke. The driver has two responsibilities:
8784

88-
1. Executing IL code
85+
1. Running portable apps
8986
2. Executing the verb
9087

91-
Which of the two things it does is dependent on what is specified on the command line. In the first case, you would
92-
specify an IL assembly that `dotnet` would run similar to this: `dotnet /path/to/your.dll`.
88+
What it does depends on what is specified on the command line. In the first case, you would
89+
specify a portable app DLL that `dotnet` would run similar to this: `dotnet /path/to/your.dll`.
9390

94-
In the second case, the driver attempts to invoke the specified command. This will start the CLI command execution
95-
process. First, the driver will determine the version of the tooling that you want. You can specify the version in the
96-
`global.json` file using the `sdkVersion` property. If that is not available, the driver will find the latest version
97-
of the tools that is installed on disk and will use that version. Once the version is determined, it will execute the
91+
In the second case, the driver attempts to invoke the specified command. This starts the CLI command execution
92+
process. First, the driver determines the version of the tooling that you want. You can specify the version in the
93+
[global.json](global-json.md) file using the [sdkVersion](global-json.md#sdkversion) property. If that is not available, the driver finds the latest version
94+
of the tools that is installed on disk and uses that version. Once the version is determined, it executes the
9895
command.
9996

10097
### The "verb"
101-
The verb is simply a command that performs an action. `dotnet build` will build your code. `dotnet publish` will publish
98+
The verb is simply a command that performs an action. `dotnet build` builds your code. `dotnet publish` publishes
10299
your code. The verb is implemented as a console application that is named per convention: `dotnet-{verb}`. All of the
103100
logic is implemented in the console application that represents the verb.
104101

105102
### The arguments
106-
The arguments that you pass on the command line are the arguments to the actual verb/command being invoked.
107-
For example, when you type `dotnet publish --output publishedapp` the `--output` argument is passed to the
103+
The arguments that you pass on the command-line are the arguments to the actual verb/command being invoked.
104+
For example, when you type `dotnet publish --output publishedapp`, the `--output` argument is passed to the
108105
`publish` command.
109106

110107
## Types of application portability
111108
CLI enables applications to be portable in two main ways:
112109

113-
1. Completely portable application that can run anywhere .NET Core is installed
114-
2. Self-contained applications
110+
1. Completely portable applications that can run anywhere .NET Core is installed
111+
2. Self-contained deployments
115112

116-
You can learn more about both of these in the [application types overview](../app-types.md) topic.
113+
You can learn more about both of these in the [.NET Core application deployment](../deploying/index.md) topic.
117114

118115
## Migration from DNX
119-
If you used DNX in RC1 of .NET Core, you may be wondering what happened to it and how do these new tools
116+
If you used DNX in .NET Core 1.0 RC1, you may be wondering what happened to it and how do these new tools
120117
relate to the DNX tools. In short, the DNX tools have been replaced with the .NET Core CLI tools.
121118
If you have existing projects or are just wondering how the commands map, you
122-
can use the [DNX to CLI migration document](../migrating-from-dnx.md) to get all of the details.
119+
can use the [DNX to CLI migration](../migrating-from-dnx.md) topic to get all the details.
123120

124121
## Extensibility
125-
Of course, not every tool that you could use in your workflow will be a part of the core CLI tools. However, .NET Core
122+
Of course, not every tool that you could use in your workflow will be part of the core CLI tools. However, .NET Core
126123
CLI has an extensibility model that allows you to specify additional tools for your projects. You can find out more
127-
in the [extensibility document](extensibility.md).
124+
in the [.NET Core CLI extensibility model](extensibility.md) topic.
128125

129-
## More resources
126+
## Summary
130127
This was a short overview of the most important features of the CLI. You can find out more by using the reference and
131128
conceptual topics on this site. There are also other resources you can use:
132-
133-
* [GitHub repo](https://github.com/dotnet/cli/)
129+
* [dotnet/CLI](https://github.com/dotnet/cli/) GitHub repo
134130
* [Getting Started instructions](https://aka.ms/dotnetcoregs/)
135-

0 commit comments

Comments
 (0)