Key Takeaways
Learn PowerShell as a command shell before treating it as a language.
Start with the prompt. Don Jones shaped this course around administrators who wanted to use PowerShell but were put off by programming-first instruction. His alternative is practical: run commands, add parameters, inspect the results, and build confidence before writing scripts. Existing command-line tools still work, while PowerShell cmdlets add a consistent way to manage Windows and connected products.
Automate what repeats. A graphical task may take minutes every time; a command that takes an hour to learn can be reused in seconds. The point is not that every task needs a script. It is that command-line fluency lets administrators choose when automation is worth the effort. The book’s short, sequential lessons are designed to fit into a working day, with practice doing as much teaching as reading.
What's striking is the order of learning: usefulness comes before mastery. That lowers the barrier for administrators who do not identify as programmers, while still giving them a path toward scripting when repetitive work demands it. The approach also makes experimentation visible: a command returns results immediately, so a learner can adjust rather than hold an entire program in mind. Its limit is that a shell-first start cannot eliminate the need to understand code when automation grows complex. It succeeds by postponing that complexity until a concrete task makes the investment worthwhile.
Make PowerShell's help system your primary tool for discovering commands.
Search before guessing. Get-Help can search topic names with wildcards, while Get-Command can locate commands by verb, noun, or command type. A search for event-related terms, for instance, can reveal commands for reading, clearing, or writing event logs. Guesses become useful when followed by a check, not when treated as facts.
Read for the details. A command’s help explains parameter sets, which parameters are optional or mandatory, which can be used positionally, and what kind of values they accept. The full help adds parameter descriptions and pipeline support; the example view shows common patterns. This turns help from a last resort into PowerShell’s substitute for menus and tooltips. Online help can be more current, and about topics explain concepts that are not tied to one command.
The help system teaches more than syntax. It trains administrators to inspect the capabilities and limits of a tool before using it, a habit that reduces both wasted effort and risky guesswork. Wildcard searches are especially valuable because they let users explore by task rather than memorize a catalog. The method does depend on documentation quality, which varies for third-party extensions and WMI. That is a reason to verify with working examples and a test environment, not a reason to abandon the habit of reading help.
Move objects through the pipeline, then format only at the end.
Pass data, not display text. PowerShell commands usually produce objects, which are structured records with properties such as a process name or service status, and sometimes methods that perform actions. Get-Member reveals those members. The pipeline carries the objects from command to command, so a later command can sort, filter, export, or act on the original data without scraping text from the screen.
Format last. Format-Table, Format-List, and Format-Wide create display instructions, not ordinary objects. Put one at the end of the pipeline, or send its output to a text file or printer. For reusable data, export objects to CSV or CliXML; for a simple report, convert them to HTML. Mixing different object types in one pipeline can produce confusing output.
This distinction is the book’s central technical payoff. Treating output as structured data makes command composition more robust than relying on column positions or printed text. It also explains why formatting too early breaks later steps: once the data has become display instructions, downstream commands no longer receive the original objects. The model is powerful, but it asks learners to keep track of what kind of object is in the pipeline at each stage. Get-Member and small experiments make that invisible movement easier to see.
Filter at the source, and exploit matching parameter names.
Reduce work early. When a command can retrieve only the records you need, use its own filtering options. If it cannot, Where-Object can inspect each object and retain those that meet a comparison, such as services whose status is Running. The book calls putting a filter as far left as possible “filter left,” because later commands then handle fewer objects.
Let names connect data. Pipeline binding can pass objects ByValue when their type matches a parameter, or ByPropertyName when an object’s property name matches a parameter name. This makes a CSV file with columns corresponding to New-ADUser parameters a convenient source for creating accounts. If names do not match, Select-Object can create or rename properties. Parentheses offer another route when a command’s output should become a parameter’s value.
Early filtering is both a performance strategy and a reasoning strategy: irrelevant records never enter the rest of the workflow. Property-name binding adds a useful form of interoperability, allowing a data file to become an input contract for a command. That convenience depends on exact naming and on understanding the receiving command’s parameters. A well-formed input file is therefore not merely administrative paperwork; its headers determine whether automation can connect cleanly. When the source data is inconsistent, an explicit transformation step is safer than hoping the shell will infer intent.
Run remote work where the data lives, not after hauling it home.
Use remoting deliberately. PowerShell remoting uses WinRM to establish command-line access to another computer. Enter-PSSession opens an interactive connection to one machine; Invoke-Command runs work on one or many machines. Enable-PSRemoting configures a computer to accept connections. For repeated access, New-PSSession creates reusable connections that can be used with either command.
Keep processing remote. Results sent back through remoting are serialized and reconstructed on the local machine, so they are snapshots rather than live objects. They may not retain methods, and actions performed afterward may target the wrong computer. Filter or modify data on the remote computer, then return the results. Implicit remoting extends this idea: commands available on a remote server can be imported as local-looking shortcuts, even when their supporting tools are not installed locally.
Remoting changes the scale of administration: one command can handle many computers, while each machine performs its own share of the work. Reusable sessions reduce repetitive connection setup, and implicit remoting can spare administrators from installing every product’s tools on their workstation. The snapshot behavior is the crucial qualification. A remote result may look like a familiar object without behaving like one, so commands that change state belong inside the remote execution. That boundary between local display and remote action deserves deliberate attention.
Reach for WMI when purpose-built cmdlets leave a management gap.
Know WMI’s map. Windows Management Instrumentation organizes management data into namespaces, classes, and instances. A class describes a kind of component, such as a logical disk; each instance represents an actual one. Properties expose information, and some instances offer methods for actions. Get-WmiObject retrieves classes, supports filters, and can query remote computers.
Expect uneven terrain. WMI can expose details that ordinary cmdlets do not, but its coverage and documentation vary. Some classes are well documented; others are difficult to discover, and the same feature may behave differently across Windows versions. A WMI Explorer or a targeted web search can help locate a class. Use a normal cmdlet when one meets the need; use WMI when it fills a real gap, and test any method before relying on it.
WMI is presented as both a valuable back door and an imperfect one. Its common structure lets administrators reach a broad range of system information with one PowerShell command, but WMI itself was not consistently designed or documented across products. That inconsistency makes discovery part of the work. The practical rule is sound: learn the cmdlet-first route, then use WMI when necessary. This avoids treating a powerful but irregular interface as the default simply because it can reach deep into the operating system.
Use batch cmdlets first; enumerate objects only as a fallback.
Prefer one action for many objects. Some cmdlets accept a collection from the pipeline and apply an action to each item. Piping several services to Stop-Service is simpler than writing a loop that stops them individually. A -PassThru option can return the objects after an action, allowing a follow-up command to verify the result.
Fall back when needed. If no suitable cmdlet can perform the action, ForEach-Object can process objects one at a time. For WMI, Invoke-WmiMethod can call a method on a group of compatible objects; if that fails or is unsuitable, ForEach-Object can invoke the method individually. This is more explicit and sometimes more cumbersome. Use the method that fits the task, but do not write a loop when a batch cmdlet already does the job.
The progression from batch command to individual enumeration is a practical way to manage complexity. A cmdlet that accepts many objects hides repetitive mechanics and often expresses the administrator’s goal more clearly. Enumeration remains essential when the available interface lacks a batch operation, especially for object methods. The distinction also discourages importing programming habits without checking whether PowerShell has a more direct command. The best choice is not the most sophisticated-looking syntax; it is the clearest reliable operation the available tools support.
Turn working commands into reusable functions that return objects.
Build from a proven command. First get the desired result interactively. Then move the command into a script, replace values that change with parameters, and add help so another administrator knows how to use it. Functions can separate one task from another, while a module packages related functions for reuse. Advanced functions can accept input from parameters or the pipeline and validate required values.
Return data, not hand-built reports. A function that writes formatted text is difficult to reuse. A function that creates an object with named properties can feed Format-Table, Export-CSV, or ConvertTo-HTML. For more complex tasks, If and Switch handle decisions, while For and ForEach repeat actions. The book’s progression is incremental: command, script, function, then module.
This path preserves the immediacy of the command line while adding structure only when reuse demands it. The emphasis on returning objects is especially important: it keeps a function composable rather than locking it into one display format. Separating tasks also makes maintenance easier, since a change to input handling need not rewrite the core operation. The danger is overengineering a short command into a framework. The book’s command-first progression provides a useful restraint: package only what has proved useful and repeatable.
Debug by testing expectations, not by changing everything at once.
Separate errors from bugs. Syntax errors usually point to a misspelled name, missing space, or mismatched punctuation. Logic errors are harder: the command runs, but its result differs from what the author expected. Write down what each line should do, then compare that expectation with the actual values and output. Write-Debug can expose variable contents and branches; breakpoints can pause execution at a line, variable access, or command.
Handle predictable failures. Nonterminating errors normally display a message and let processing continue. The -ErrorAction parameter can turn them into terminating exceptions for a particular command, which a Try/Catch block can handle. -ErrorVariable can capture error details. Avoid suppressing errors globally: it can hide both expected failures and the clues needed to find genuine bugs.
The debugging method is a disciplined comparison between a mental model and the program’s actual behavior. This is more reliable than shotgun debugging, where unrelated changes make it harder to identify the cause. Trace messages and breakpoints turn hidden state into observable evidence, while scoped error handling distinguishes a known failure from a broken script. The approach also improves design: a command that is difficult to inspect is difficult to trust. Predictable failures should be handled, but broad suppression trades a quieter screen for less information.
Treat script security as control over trust, not a malware shield.
Know what execution policy does. PowerShell’s default Restricted setting prevents ordinary scripts from running. RemoteSigned permits local scripts and requires signatures for scripts treated as remote; AllSigned requires a trusted signature for every script. A digital signature identifies the signer and helps detect changes made after signing. Policies can be configured locally or through Group Policy, and centralized policy can override a local setting.
Keep the boundary clear. Execution policy is meant to reduce the chance that someone is tricked into running an untrusted script. It does not add permissions, bypass existing access controls, or protect a computer already compromised by malware. Users can still type commands they are authorized to run. Review scripts from outside sources, keep anti-malware protections, and choose a policy that fits the organization’s rules.
The useful security lesson is precision: execution policy is a guard against accidental script execution, not a general-purpose defense system. Confusing those roles can create false confidence or lead to needless restrictions that impede legitimate work. Signatures help establish provenance and detect tampering, but trust still depends on who issued the certificate and how carefully its identity was verified. The book’s strongest point is that PowerShell exercises the user’s existing authority. Security therefore remains a property of permissions, operational controls, and informed choices, not of the shell alone.
Analysis
This book’s teaching argument is also its organizing principle: administrators should learn PowerShell as a working shell before being asked to think like programmers. The sequence begins with familiar command-line tasks, then introduces help, pipelines, objects, filtering, remoting, WMI, and automation. Scripting arrives only after the reader has seen how much can be accomplished without it. That order matters because it gives abstract ideas a practical job to do. Objects are not introduced as a computer-science topic in isolation; they explain why a pipeline can move useful data between commands without parsing printed text.
The strongest conceptual thread is composability. A command retrieves, transforms, or acts on data; a pipeline connects those operations; a function makes a proven sequence reusable; a module distributes it. The repeated instruction to inspect help and test small examples is not filler. It is the book’s answer to PowerShell’s enormous surface area. Rather than catalog every product command, it teaches a method for discovering the next one.
Its limits are visible in the same design. The examples rely on PowerShell v2 and Windows Server 2008 R2, so particular tools and installation steps are historically specific. WMI is uneven, and some advanced syntax can be hard to read. The text acknowledges these rough edges but cannot make them disappear. Nor does a month of short lessons guarantee fluency without practice. Its value is a durable operating model: start with a task, inspect the available command, follow the objects through the pipeline, test the result, and add structure only when repetition or complexity justifies it. That model travels further than any individual cmdlet.
Review Summary
Learn Windows PowerShell in a Month of Lunches receives mostly positive reviews, with an average rating of 4.30 out of 5. Readers appreciate its practical approach, easy-to-digest chapters, and hands-on exercises. The book is praised for its accessibility to beginners while still offering valuable insights for experienced users. Many reviewers highlight its effectiveness in teaching PowerShell fundamentals and how to learn independently. Some criticisms include outdated content for newer PowerShell versions and platform-specific examples. Overall, readers recommend it as an excellent starting point for learning PowerShell.
Glossary
cmdlet
PowerShell commandA cmdlet is a native PowerShell command, commonly named with a verb and a singular noun separated by a hyphen, such as Get-Service. Cmdlets accept parameters, produce objects, and can pass those objects through the pipeline. Their consistent naming and parameter conventions help users discover and combine commands.
PSDrive
Storage mapped as a driveA PSDrive maps a data store into PowerShell so it can be navigated with familiar commands. The filesystem and registry have built-in PSDrives, and additional providers can expose other stores. A PSDrive exists within PowerShell rather than necessarily appearing as a drive in Windows Explorer.
pipeline
Object flow between commandsThe pipeline passes the output objects of one command to another command for further work. Because those objects retain their properties, later commands can filter, sort, transform, export, or act on them without extracting information from screen text. Formatting should generally happen at the end, after data processing is complete.
pipeline parameter binding
Matching piped input to parametersPipeline parameter binding is PowerShell’s process for connecting incoming objects to a command’s parameters. The shell first tries ByValue binding, which matches the object’s type to a parameter that accepts pipeline input. If that fails, it tries ByPropertyName, matching incoming object property names to eligible parameter names.
filter left
Filter as early as possibleFilter left is the practice of applying selection criteria as close as possible to the command that retrieves the data. When a command can filter at the source, it returns fewer objects for later commands to process. If it cannot, a filtering command such as Where-Object can remove unwanted objects farther along the pipeline.
WMI
Windows management information systemWindows Management Instrumentation is a Windows system for exposing management information and, in some cases, actions. Its data is organized into namespaces, classes, and instances. PowerShell’s Get-WmiObject retrieves instances, whose properties hold information and whose methods may perform operations. WMI coverage and documentation vary across products and Windows versions.
PSSession
Reusable remote connectionA PSSession is a persistent PowerShell connection to a remote computer. It can be created with New-PSSession and reused with commands such as Enter-PSSession or Invoke-Command, avoiding repeated connection setup. Sessions consume some resources while open, so they should be removed when no longer needed.
implicit remoting
Remote commands used locallyImplicit remoting imports commands from a remote PowerShell session so they appear available in the local shell. The commands still execute on the remote computer, which can provide access to tools that are not installed locally. Returned objects are serialized snapshots and may not retain their original methods.
execution policy
Script-running restriction settingPowerShell’s execution policy controls which scripts the shell will run, with settings ranging from Restricted to Unrestricted and a separate Bypass option. Policies can require digital signatures for remote or all scripts. The policy is intended to reduce accidental execution of untrusted scripts, not to add permissions or replace anti-malware protection.
advanced function
Function with cmdlet-like behaviorAn advanced function is a PowerShell function that uses cmdlet-style parameter attributes. It can accept pipeline input, mark parameters as mandatory, define aliases, and support features such as confirmation and WhatIf behavior. Advanced functions let authors package reusable operations in a form that behaves much like a built-in cmdlet.
Download PDF
Download EPUB
.epub digital book format is ideal for reading ebooks on phones, tablets, and e-readers.