-
.NET Core Solution & Project Utilities (slnutil)
Announcing the Solution & Project Utilities (slnutil)! These are a collection of the handy utilities that I’ve written for working with .NET Core Solutions, Projects, and configuration files. I hope you find them useful.
-
C#: How to Find All Files Including Hidden Files?
I was writing some code yesterday that needed to enumerate all files in a directory. So I wrote what I’ve been writing since the beginning of time: var files = Directory.GetFiles(“*.*”, new EnumerationOptions { RecurseSubdirectories = true }); At first, it seemed to be working just fine but then I noticed that hidden files were…
-
A Handy Script for .NET Developer Containers on Docker
I’m a .NET Core developer and I mostly work on a Mac. Before docker and containers, this would have been hard to do. But now there are containers for SQL Server, the Azure Storage emulator, and the CosmosDb emulator. Developing on a Mac is easy now. And developing on a Mac makes it easy to…
-
GitHub Actions for Building, Testing, and Deploying .NET Core & ASP.NET Core Apps
Seems like there’s a lot of action(s) happening over on GitHub. How do I get a piece of that action(s)? Wheee! Puns! (I’ve been cooped up in my house too long.) So if you’re a .NET Core developer or an ASP.NET Core developer who maybe uses Entity Framework Core (EF Core), how do you deploy your apps using GitHub…
-
Force ‘dotnet publish’ to publish dependencies using PublishWithAspNetCoreTargetManifest
I ran into a problem today doing an automated build for a ASP.NET Core 2 project and then trying to deploy the output. From the command line, I ran “dotnet publish -o c:\temp\presidents” to build and publish the code for my ASP.NET Core web application. Then I went to the directory that I just published…
-
“DevOps with ASP.NET Core, EF Core, & TFS2017”: Slides & Code
[Updated 3/23/2017 — If you saw this talk at DevBoston or Code Camp Boston, it’s the same slides and code at NYC .NET.] I spoke at the NYC .NET Developers user group last night and gave my new “DevOps with ASP.NET Core, EF Core, & TFS2017” talk. DevOps is all about software delivery. Create an…
-
Deploy Entity Framework Core Migrations from a DLL
[Updated 4/27/2018 — Added an EF Core 2 version of this script in a new blog post.] [Updated 3/29/2017 — Added a bash version of this script for deploying EF Core Migrations from Linux.] Entity Framework Migrations let you deploy incremental updates to a target database. With Entity Framework Core (EF Core) this is done from…
-
TFS Build / Release Configuration Utilities: Edit app.config, web.config, appsettings.json, and XML
When you’re working automated builds and automated releases, you frequently need to edit configuration files like app.config, web.config, and appsettings.json. Well, I wrote a command line utility to do this and I figured I’d share. I’ve got a version that is an .exe that can be used on a Windows build agent and I’ve got a version that’s written…
-
Walkthrough: Entity Framework Core 1.1 with Migrations
Here’s a walk-through on how to create a new solution that uses an ASP.NET Core project, an MSTest unit test project, and Entity Framework Core 1.1 (EFCore1.1). I’m not sure if you’ve found this to be the case but I’ve been struggling with the documentation for a few days trying to figure out how to…
-
Script: Create new ASP.NET Core Project with Class Library & Tests
Building on my post about how to do some common Solution and Project tasks using the dotnet command, here’s a sample script to create a complete solution that can be used from Visual Studio 2017 or Visual Studio Code. I wanted to be able to create a complete solution and project structure all from the…