Yesterday I posted an article on how to convert a selected word to an alias or cmdlet. While I think there is still some value in this piecemeal approach. sometimes you want to make wholesale changes, such as when troubleshooting a script that someone else wrote that is full of cryptic aliases. I have a…
Tag: Regular Expressions
Convert Transcript to Script
During my PowerShell scripting best practices at Techmentor last week I mentioned a function I had to convert a PowerShell transcript to a script file. Since there’s very little difference between an interactive session and a script, parsing the transcript can yield 80% or more of a script very quickly. I wrote such a function…
PowerShell Regular Expressions by the Numbers
I’ve been working on something the last week that brought me back into sometimes frightening world of regular expressions. But as the saying goes, we only fear what we don’t understand. So a little knowledge can be a wonderful thing. In this particular situation I was looking for a regular expression to determine if a…