Development & Code
Building a PowerShell Deploy Script: Discovering Components From Disk
Part five: how the script works out its own components, deploy order, publish profiles and targets from the repos on disk, with no hand-maintained list to rot.
Part five: how the script works out its own components, deploy order, publish profiles and targets from the repos on disk, with no hand-maintained list to rot.
Part four: the two required inputs, why the git branch is never allowed to pick the environment, and a branch guard that stops a runner shipping the wrong code.
The skeleton of a real deploy script: the parameter surface, accepting input three ways, detecting automation instead of declaring it, and a menu that can never hang a pipeline.
A high-level look at building one PowerShell script to compile, test and publish a large multi-project .NET solution across environments, and the MSBuild and NuGet gotchas I hit along the way.