dotnet --info

PS E:\GitHub\KerryJiang\SuperSocket> dotnet --info
.NET Command Line Tools (2.1.4)

Product Information:
Version: 2.1.4
Commit SHA-1 hash: 5e8add2190

Runtime Environment:
OS Name: Windows
OS Version: 10.0.10586
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\2.1.4\

Microsoft .NET Core Shared Framework Host

Version : 2.0.5
Build : 17373eb129b3b05aa18ece963f8795d65ef8ea54

dotnet new console -o hwapp

dotnet restore

dotnet run

dotnet new

Creates a new project, configuration file, or solution based on the specified template.

Description

The dotnet new command provides a convenient way to initialize a valid .NET Core project.

The command calls the template engine to create the artifacts on disk based on the specified template and options.

dotnet restore

Restores the dependencies and tools of a project.

Description

The dotnet restore command uses NuGet to restore dependencies as well as project-specific tools that are specified in the project file. By default, the restoration of dependencies and tools are performed in parallel.

In order to restore the dependencies, NuGet needs the feeds where the packages are located.

Feeds are usually provided via the NuGet.config configuration file.

A default configuration file is provided when the CLI tools are installed.

You specify additional feeds by creating your own NuGet.config file in the project directory.

You also specify additional feeds per invocation at a command prompt.

For dependencies, you specify where the restored packages are placed during the restore operation using the --packages argument.

If not specified, the default NuGet package cache is used, which is found in the .nuget/packages directory in the user's home directory on all operating systems (for example, /home/user1 on Linux or C:\Users\user1 on Windows).

For project-specific tooling, dotnet restore first restores the package in which the tool is packed, and then proceeds to restore the tool's dependencies as specified in its project file.

The behavior of the dotnet restore command is affected by some of the settings in the Nuget.Config file, if present.

For example, setting the globalPackagesFolder in NuGet.Config places the restored NuGet packages in the specified folder.

This is an alternative to specifying the --packages option on the dotnet restore command.

For more information, see the NuGet.Config reference.

异常处理

PS D:\ChuckLu\Git\GitHub\KerryJiang\IrvineCSharpCourses> dotnet restore
MSBUILD : error MSB1003: Specify a project or solution file. The current working directory does not contain a project or solution file.

这个命令需要在项目或者解决方案下运行才有效

dotnet run

Runs source code without any explicit compile or launch commands.

Description

The dotnet run command provides a convenient option to run your application from the source code with one command.

It's useful for fast iterative development from the command line.

The command depends on the dotnet build command to build the code.

Any requirements for the build, such as that the project must be restored first, apply to dotnet run as well.

Output files are written into the default location, which is bin/<configuration>/<target>.

For example if you have a netcoreapp1.0 application and you run dotnet run, the output is placed in bin/Debug/netcoreapp1.0.

Files are overwritten as needed.

Temporary files are placed in the obj directory.

If the project specifies multiple frameworks, executing dotnet run results in an error unless the -f|--framework <FRAMEWORK> option is used to specify the framework.

The dotnet run command is used in the context of projects, not built assemblies. If you're trying to run a framework-dependent application DLL instead, you must use dotnet without a command. For example, to run myapp.dll, use:

 
dotnet myapp.dll

For more information on the dotnet driver, see the .NET Core Command Line Tools (CLI) topic.

In order to run the application, the dotnet run command resolves the dependencies of the application that are outside of the shared runtime from the NuGet cache. Because it uses cached dependencies, it's not recommended to use dotnet run to run applications in production. Instead, create a deployment using the dotnet publish command and deploy the published output.

dotnet --version

PS E:\GitHub\KerryJiang\SuperSocket> dotnet sln .\SuperSocket.sln list
Project reference(s)
--------------------
src\SuperSocket.Primitives\SuperSocket.Primitives.csproj
src\SuperSocket.ProtoBase\SuperSocket.ProtoBase.csproj
src\SuperSocket.NetSocket\SuperSocket.NetSocket.csproj
src\SuperSocket.Libuv\SuperSocket.Libuv.csproj
test
test\Test\Test.csproj
src\SuperSocket.Server\SuperSocket.Server.csproj
src\SuperSocket.Channel\SuperSocket.Channel.csproj

-v|--verbosity <LEVEL>

Sets the verbosity level of the command. Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic].

最新文章

  1. Fixing DSDT
  2. 一台MySQL服务器启动多个端口
  3. HTTP协议从入门到大牛,初识HTTP协议(学习笔记)
  4. Windows Phone 8 显示当前项目的使用内存,最大峰值,最大内存上限
  5. 改进iOS客户端的升级提醒功能
  6. 百度之星热身赛-1001(dfs拓扑排序)
  7. 统计学习方法笔记 -- Boosting方法
  8. 10个常见的IE bug和解决方法
  9. lazyload 图片延迟加载
  10. Apache http强制转为https页面访问(转)
  11. poj 2041 Unreliable Message 字符串处理
  12. 拉姆达表达式 追加 条件判断 Expression&lt;Func&lt;T, bool&gt;&gt;
  13. 帧同步(LockStep)该如何反外挂
  14. vs编码对编译的影响(UTF-8 no BOM编译通不过)
  15. Python: 猴子分桃。海滩上有一堆桃子,五只猴子来分。
  16. hdu 5182 结构体排序
  17. WCF揭秘学习笔记(5):WF定制活动
  18. windows下beautifulsoup使用lxml解析使用报错
  19. Visual Studio 2013打开项目出现“未安装项目的目标框架”提示
  20. Selenium2+python自动化33-文件上传(send_keys)

热门文章

  1. C语言声明语句
  2. vmware vsphere出现“需要整合虚拟机磁盘”的告警处理方法(完整版)
  3. vue之computed和watch
  4. Adobe Flex迷你教程 —Flex4全屏显示
  5. Maven项目的坐标GroupId和ArtifactId
  6. 新手做2D手游该用哪些工具?
  7. UVALIVE 4287 Proving Equivalences (强连通分量+缩点)
  8. TOMCATserver不写port号、不写项目名訪问项目、虚拟文件夹配置
  9. C++primer读书笔记11-多态
  10. css 清楚浮动的8种方式