My Profile Photo Title

Thoughts about DevOps and automation from a Windows guy


  1. How to Process File Paths from the Pipeline in PowerShell Functions

     feature image

    The correct way to write a PowerShell function that works with file paths from the pipeline requires some effort, but it will make your PowerShell scripts work more reliably. >>


  2. How to Run a PowerShell Script as a Windows Service

     feature image

    If you have a PowerShell script you'd like to run constantly in the background and start up automatically after a reboot, the best option is to run it as a Windows service. I'll show you how to set this up using NSSM, the Non-Sucking Service Manager. >>


  3. Infrastructure Testing with Pester and the Operation Validation Framework

     feature image

    If you've been using PowerShell for any length of time in the past few years you have undoubtedly heard of Pester. If not, then you're probably living in a strange parallel universe where the Zune is still a thing. In any case, Pester is THE testing framework for PowerShell and is a must-have tool in your Infrastructure Developer toolbox. >>


  4. PowerShell Strict Mode

     feature image

    With the Set-StrictMode cmdlet you can turn PowerShell’s Strict Mode on, which ensures that you follow best practices in your script. I'll show you the differences between Strict Mode versions 1.0 and 2.0. >>


  5. How to Write PowerShell for Speed

     feature image

    Sometimes speed and efficiency are not that important when writing quick and dirty PowerShell scripts. At other times they are critical. I'll highlight some of the common mistakes people make when writing PowerShell scripts that cause it to slow to a crawl. >>