rendle.dev

Mark Rendle's .NET development blog.

Nullable References in Enumerables

Handling nullable reference types in IEnumerable operations

2-Minute Read

I’m a big fan of the Nullable Reference Types feature added in C# 8.0. It lets the compiler catch a bunch of potential runtime errors, and I guarantee if you turn it on you’ll get a bunch of warnings. As of .NET 5.0, the entire BCL is now covered with nullable annotations, and a lot of the extended ecosystem supports them too.

Creating a dotnet tool

Building, packaging and publishing a `dotnet` tool via NuGet

9-Minute Read

One of the great features of .NET Core is that it gives you a simple way to create and distribute CLI tools via NuGet. You just create a Console application, add a few entries to the .csproj file, and publish it to NuGet. Then other people can install it with the dotnet tool install command. I’ve published a couple of tools this way before, but I’ve just published another one so I thought I’d take time to describe the steps involved, as well as a handful of neat NuGet packages…

Recent Posts

Categories

About

Mark Rendle's blog about making software and stuff.