Ramblings about my programming escapades.

PS for .NET devs part 5: Extending Visual Studio using StudioShell


In a previous post I showed how to extract all targets defined in a given MSBuild file. Wouldn’t it be great if the execution of those targets could be performed directly from within Visual Studio. Building on PowerShell and StudioShell this becomes trivial. PowerShell Hosts in Visual Studio Looking in the Visual Studio Extension Manager you find a number of extensions that offer PowerShell related functionality for Visual Studio, below I’ll briefly describe them:…
Read more ⟶

PS for .NET devs part 4: Source digging


The kind of adhoc scripting you can do with PowerShell lends it’s self very well for getting an overview of the code-base you find yourself in. When you find yourself in a project or you’re just interested in some basic statistics/metrics about your code-base you could follow something like the path I’m about to uncover. For brevity and a real life flavor I’m using the short form aliases of the Cmdlets look them up with Get-Alias if you find any that are unfamiliar.…
Read more ⟶

PS for .NET devs part 3: List Targets in your MSBuild file


The project I’m currently working on, started more than five years ago and has quite a large MSBuild file to perform all the build automation for the project. A while back I found myself struggling to remember the name of a specific build Target that I don’t use very often. Since such a large XML file is not as readable as one would hope I couldn’t find what I was looking for fast enough.…
Read more ⟶