Environment:
1, Centos7
2. dotnet Core 1.0.0-preview1-002702
Steps:
1. Installation environment, specify the installation directory as ~/dotnet
Curl-ssl https://raw.githubusercontent.com/dotnet/cli/rel/1.0.0-preview1/scripts/obtain/dotnet-install.sh | Bash/dev/stdin--version 1.0.0-preview1-002702--install-dir ~/dotnet
2. Create a soft connection
sudo Ln -S ~/dotnet/dotnet/usr/local/bin
3. Create a project
# Create a folder mkdir hwapp# Enter folder CD hwapp# Create project dotnet new
4. Restore NuGet dependencies, compile and run the project
#还原nuget依赖dotnet restore# compile and run dotnet run
5. Operation Result
[email protected] hwapp]# dotnet runproject Hwapp (. Netcoreapp,version=v1. 0 for. Netcoreapp,version=v1. 0 compilation succeeded. 0 Warning (s) 0 xx:04.9785477 HelloWorld!
Reference:
Https://www.microsoft.com/net/core#centos
"Netcore Primer" centos7.x netcore Environment and HelloWorld Demo