Install PowerShell 7 with Jeff Hicks’ PSReleaseTools Module

PowerShell version 7 is currently in preview and while it can be installed on Windows, Linux, and macOS, the examples shown in this blog article focus on installing it on a Windows based system, specifically Windows 10 using Windows PowerShell version 5 or higher which ships by default with Windows 10. Your mileage may vary with other operating systems, other versions of Windows, and/or other versions of Windows PowerShell. The easiest way that I’ve found to install the preview of PowerShell version 7 is to first install Jeff Hicks' PSReleaseTools PowerShell module from the PowerShell Gallery using Windows PowerShell....

July 11, 2019 · 2 min · 235 words · Mike F. Robbins

PowerShell Core 6: ValidatePattern Custom Error Messages

Last week, I received a comment on my previous blog article from fellow Microsoft MVP Joel Bennett which referenced using an ErrorMessage parameter similar to how ValidatePattern works in PowerShell Core version 6. I knew I’d seen some discussion about this on GitHub, but I wasn’t aware that it had made it into the production release. Joel’s message is shown in the following image. I had to figure out how to use custom error messages with ValidatePattern....

May 3, 2018 · 2 min · 258 words · Mike F. Robbins

Help in PowerShell Core is independent of help in Windows PowerShell

You’ve decided to install PowerShell Core on your Windows system. First of all, keep in mind that PowerShell Core version 6.0 is not an upgrade or replacement to Windows PowerShell version 5.1. It installs side by side on Windows systems. Being aware of this makes what is shown in this blog article make more sense, otherwise it can be confusing. Based on the response to a tweet of mine from Don Jones, it appears that I’m not the only one who thought PowerShell Core should have been version 1....

January 27, 2018 · 2 min · 300 words · Mike F. Robbins