I had a good friend the other day ask the Community.
“I want to learn Powershell? What books should I read? Where do I start?”
And the problem is that you will get 100 answers, all of them correct.
The problem is that Powershell, as it’s name implies is incredibly POWERFUL. And to a new person taking a look at the online community and the features it has, it can be overwhelming at the amount of available scripts written by people.
And you may have the same reaction I had. “Oh I could NEVER do ANYTHING like those scripts, I should just shut up so I don’t look stupid…”
And that’s the flaw.
The material online for Powershell all started somewhere. Everybody knew NOTHING about it at one point or another. And your best resource is those magic six words.
“I don’t know, I’ll go ask…”
What actually seems to work for me is something as simple as (and that’s how I started learning) “I have a need to repeat something en masse or for consistency.”
If it can be done in a Login Script, it gets done there. GPO there.
If’ it has anything at all on ANY level to do with WMI, Active Directory, working with the Registry, manipulating files, date, logs, Powershell.
So what helped me learn Powershell was that magic thing that drives all ITPros and Devs. “I NEED a solution. I need one I can easily repeat and replicate with consistency.”
What I found worked best for me was to realize I was “repeating something” and could this be scripted in any way? The reason for this was with an automated solution, the results were more consistent and faster. So to learn Powershell, find a need you have. Learn how to do that NEED in Powershell. The solution is probably online. And once have it full filled, you may want to understand how that solution works, and why.
The Syntax of the language is simple. A “VERB-NOUN” structure. Running a “GET-COMMAND” will show you all the commands, “ALIAS” will show you all the Aliases.
That doesn’t teach you Powershell. What teaches you Powershell is just using it, for something simple. Get comfortable with just ONE feature. Even if it’s just using “GET-CHILDITEM” to navigate the file System. Get really comfortable with using that one feature with a “GET-MEMBER” to learn how to pull out properties (information) and Methods (functions which modify the output)
In short, Play with Powershell on a small level and get comfortable with it. Because ALL of the fancy stuff, all the nifty stuff all works the same way.
And don’t be afraid to ask, nobody in the Powershell community thinks there are silly questions.
Because one day, we were all asking them ourselves.
The Energized Tech