.NET Core Blimey: Volume 1

May 15, 2016 - dotnet-core-blimey

I’ve been working with .NET Core and its ASP.NET counterpart for a few months now. Initially I was using DNX on top of .NET 4.6 which was a fairly normal development experience – everything worked through Visual Studio and it runs on Windows only – fairly traditional. But I’ve recently started a new project and decided to take the leap to the new dotnet CLI. It has proven to be a true rollercoaster ride. Things will compile one day and fail the next, with methods being moved between namespaces, renamed or simply just deleted. Nuget packages will update and need the latest version of the CLI to be downloaded for your project to function again. But amongst all of this, it’s an absolutely fascinating time to be developing on the .NET stack as it is moving at such a fast pace, the likes of which Microsoft developers have never seen before. And the fact that it is all open source means that if you find a bug, instead of going to a forum in the depths of MSDN to be told it’s a known bug and that it’ll be fixed “soon” you can submit an issue on github and it will be fixed within a couple of days. As it everything is moving at such a hectic pace, I decided that I should chronical my bumps and triumphs along the way, as a record for myself, but also any passing Googlers that have the same issues.

This week saw me moving 100% over to development on OSX instead of on Windows – after all, using Visual Studio Code and the Core framework give you the same experience!

Visual Studio Code

  • News: VSCode updated to v1.1.0 (April 2016)
  • Walkthrough: Getting Visual Studio Code up and running with Dotnet CLI RC2 and ASP.NET
    1. Cmd + Shift + P, ext install, Built-in Omnisharp
    2. Download latest VISX from https://github.com/OmniSharp/omnisharp-vscode/releases/ and open from within Visual Studio Code (File>Open)
    3. Go to debug, select .NET Core from the cog
    4. Select .NET Core Launch (web) from the drop down
    5. If your project.json isn’t at root level, you need to update the "program" and "cwd" paths in launch.json and add "args": [ "${cwd}/src/my_project_folder" ], to tasks.json. See Omnisharp’s guide for more information
  • Top tip: To enable full Intellisense in Visual Studio Code, click the little green “Select Project” in the bottom right and select the project you’re working on.

Dotnet CLI


  • Walkthrough: Hosting an ASP.NET Core 1.0 RC2 app on an Azure App Service
  • Top tip: Make sure that the App Service instance is set to be in x64 bit mode!
  • Word of warning: If you’re getting 500 errors and your app isn’t working and can’t figure out why, check your web.config in vim to see if there are any strange (non printing) symbols in it