Skip to content

002: Setup

Shane DeSeranno edited this page Feb 10, 2017 · 2 revisions

If you are following along with .NET Core, you can create an empty folder do this work. If you are using another technology, you should use this section to create an empty console application and get ready to write code. Also, if you are just "reading along", just skip to the end and checkout to the Setup tag.

Go to an empty folder
mkdir src\SSHServer
cd src\SSHServer
dotnet new
cd ..\..
mkdir test\SSHServerTests
cd test\SSHServerTests
dotnet new -t xunittest
cd ..\..
Create global.json with:
	{
	  "projects": [ "src", "test" ]
	}
dotnet restore
dotnet build src\SSHServer
dotnet build test\SSHServerTests
dotnet test test\SSHServerTests
Create VS solution
- Open src\SSHServer\project.json
- Save As and go up to the root directory and save
- Add Existing project and choose test\SSHServer\project.json
- Add Existing Items for: .gitignore, global.json, LICENSE, README.md (as appropriate)
- Create solution folder for: 'src' and 'test' and move projects into the correct folders
Note: you may need to update the test\SSHServerTests\project.json to:
	"dotnet-test-xunit": "2.2.0-preview2-build1029"

After completing these steps, we should have everything setup as in the "Setup" tag in Git.

In the next step, we'll setup the server to listen for connections. Proceed to Listening for Connections!