.NET Core and Visual Studio Code
.NET Core gives you a blazing fast and modular platform for creating server applications that run on Windows, Linux and Mac. Use Visual Studio Code with the C# extension to get a powerful editing experience with full support for C# IntelliSense (smart code completion) and debugging.
If you'd like to get started with a simple "Hello World" program on .NET Core, follow the steps below:
- Initialize a C# project:
- Open the command prompt (or terminal).
- Navigate to the folder where you'd like to create the C# project.
- This creates a
Program.csfile in your folder with a simple "Hello World" program already written.
- Resolve the build assets by typing
Tip: If you are using the MSBuild-based .NET Core Tools, a .csproj project file will be created instead of a project.json, but the
dotnetcommands remain the same. Read more.
restorepulls down the required packages declared in the
- You'll see a new
project.lock.jsonfile in your project folder.
- This file contains information about your project's dependencies to make subsequent restores quicker.
- There will be a notification that appears at the top of the window asking if you'd like to add the required assets to build and debug your project. Select Yes.
- Run the "Hello World" program by typing
Tip: Continue exploring C# development: Debug with VS Code and .NET Core
- Editing Evolved - Lint, IntelliSense, Lightbulbs, Peek and Go to Definition and more
- Working with C# - Learn about the great C# support you'll have when working on your .NET Core application.
- Tasks - Running tasks with Gulp, Grunt and Jake. Showing Errors and Warnings
- .NET Core Docs - Visit the .NET Core docs for more information on this powerful cross-platform development solution.