Chapter 1: Before you begin
This introduction frames PowerShell as a command-line shell that beginners can start using without learning to script first.
After this chapter you will be able to
- PowerShell as a command-line shell. Explain that PowerShell is a command-line shell for running commands, with scripting capabilities that are optional when getting started.
- Earlier Windows automation tools. State that Windows administrators had automation options before PowerShell, including Batch, KiXtart, and VBScript.
- GUI discovery and repetition. Explain why a GUI is useful for discovering and learning administrative tasks but offers little time savings when the same task must be repeated many times.
- VBScript savings and last mile. Describe how a VBScript could repay the time spent writing it through fast repeat work, and explain why incomplete access to product features could still leave a task unfinished.
- PowerShell beneath administrative GUIs. Explain Microsoft's goal of making a product's administrative functionality accessible through PowerShell, even when administrators use a GUI, and why direct PowerShell access helps with repetitive tasks or tasks the GUI handles poorly.
- PowerShell adoption and efficiency. Explain why the section says administrators can no longer afford to ignore PowerShell, connecting its growing use across products with the efficiency of automated command-line work.
- PowerShell Across Operating Systems. Explain that Microsoft open-sourced PowerShell Version 6 and released PowerShell for macOS and numerous Linux builds, making the same object-centric shell available beyond Windows.
- Primary audience and command use. Describe the three broad PowerShell audiences and explain why the book focuses on administrators who run commands and use tools written by others. Explain why learning command-use patterns also matters to people who create tools.
- Practical introductory scope. Explain the book’s goal of making readers effective with PowerShell in a production environment without covering everything PowerShell or related technologies can do.
- Daily reading and practice rhythm. Describe the suggested pace of one chapter per day, with about 40 minutes for reading and time afterward to practice what the chapter showed.
- One Chapter Daily Pace. Explain why the book recommends working through roughly one main chapter per day rather than rushing ahead, and how practice fits into that schedule.
- Free supplementary video resources. Describe the book-specific help-system video and the broader collection of free PowerShell videos available through PowerShell.org.
- Purpose of Further Exploration. Explain that some chapters only skim a technology and end with suggestions and additional resources, including free ones, for exploring it further when needed.
- Above and beyond sections. Explain that “Above and beyond” sections offer brief, optional explanations of why PowerShell works as it does, rather than many extra practical skills. Describe when a reader might skip them and return later.
- Safe practice environment. Explain why practice should happen in a lab rather than a company’s production environment, and describe how many computers the book requires.
- Windows lab requirements. Describe the suggested Windows setup and distinguish the preinstalled Windows PowerShell from the separately installed PowerShell 7.
- PowerShell version and installation sources. Describe how to check the installed PowerShell version and where to find the latest releases and installation instructions.
- Windows console readability settings. Explain why the section recommends changing the Windows text-based console font and describe how to adjust its settings.
- PowerShell community resources. Describe where the section suggests asking PowerShell questions and finding resources for continued learning, and explain why the authors welcome feedback.
- Practical First Learning Approach. Explain why the book sometimes starts with a useful PowerShell task before explaining all its theory and caveats.
Section by section
Introduction
This introduction frames PowerShell as a command-line shell that beginners can start using without learning to script first.
- PowerShell as a command-line shell: Explain that PowerShell is a command-line shell for running commands, with scripting capabilities that are optional when getting started.
Why it matters: You can begin using PowerShell by running commands, even if you have never written a script.
Key terms: command-line shell, command-line utilities, scripting capabilities
1.1 Why you can no longer afford to ignore PowerShell
This section places PowerShell in the context of earlier Windows automation tools and introduces the question of why it is worth learning.
- Earlier Windows automation tools: State that Windows administrators had automation options before PowerShell, including Batch, KiXtart, and VBScript.
Why it matters: It gives context for the later comparison between administration before and with PowerShell.
Key terms: Batch, KiXtart, VBScript, PowerShell
1.1.1 Life without PowerShell
The section explains why GUI work and earlier scripting tools left Windows administrators needing a more reliable way to automate tasks.
- GUI discovery and repetition: Explain why a GUI is useful for discovering and learning administrative tasks but offers little time savings when the same task must be repeated many times.
Why it matters: This explains why a tool that is easy to learn may still be costly for repetitive administration. - VBScript savings and last mile: Describe how a VBScript could repay the time spent writing it through fast repeat work, and explain why incomplete access to product features could still leave a task unfinished.
Why it matters: Automation saves repeated effort only if it can reach every capability the task requires. - PowerShell as a response: Explain that Microsoft intended Windows PowerShell to address the last-mile limitation, and identify the adoption the section offers as evidence of its success so far.
Why it matters: It connects the limitations just described to why the book turns to PowerShell.
Key terms: graphical user interface (GUI), Active Directory Users and Computers, VBScript, CSV file, last mile, Windows PowerShell
1.1.2 Life with PowerShell
The section explains why PowerShell has become central to administration and why automating tasks with it can be more efficient than relying on GUIs.
- PowerShell beneath administrative GUIs: Explain Microsoft's goal of making a product's administrative functionality accessible through PowerShell, even when administrators use a GUI, and why direct PowerShell access helps with repetitive tasks or tasks the GUI handles poorly.
Why it matters: PowerShell gives you a way to automate administration without being limited to what a GUI makes convenient. - PowerShell adoption and efficiency: Explain why the section says administrators can no longer afford to ignore PowerShell, connecting its growing use across products with the efficiency of automated command-line work.
Why it matters: The section presents PowerShell skill as both increasingly useful and valuable for working efficiently.
Key terms: PowerShell, GUI consoles, administrative functionality, automating, GUI
1.2 Windows, Linux, and macOS, oh my
The section explains PowerShell’s expansion beyond Windows and the limits of the book’s cross-platform examples.
- PowerShell Across Operating Systems: Explain that Microsoft open-sourced PowerShell Version 6 and released PowerShell for macOS and numerous Linux builds, making the same object-centric shell available beyond Windows.
Why it matters: You can approach PowerShell as a shell used on more than one operating system. - Cross-Platform Example Limits: Describe why not every example in the book works on macOS and Linux, and identify the stated exception to its cross-platform aim.
Why it matters: It sets realistic expectations if you follow the book on macOS or Linux.
Key terms: PowerShell Version 6, PowerShell Core, object-centric shell, macOS, Linux, cross-platform compatible, commands, Windows focused
1.3 Is this book for you?
This section identifies the book’s primary audience and sets expectations for its practical, introductory scope.
- Primary audience and command use: Describe the three broad PowerShell audiences and explain why the book focuses on administrators who run commands and use tools written by others. Explain why learning command-use patterns also matters to people who create tools.
Why it matters: Knowing the intended audience helps you judge the depth and emphasis of the lessons. - Practical introductory scope: Explain the book’s goal of making readers effective with PowerShell in a production environment without covering everything PowerShell or related technologies can do.
Why it matters: This sets realistic expectations about what the book will teach and what may need further study.
Key terms: administrators, run commands, tools, patterns, production environment, external management technologies, first step
1.4 How to use this book
This section recommends a daily rhythm for reading and practicing with the book.
- Daily reading and practice rhythm: Describe the suggested pace of one chapter per day, with about 40 minutes for reading and time afterward to practice what the chapter showed.
Why it matters: The suggested pace makes room to try what you have just read.
Key terms: one chapter each day, practice
1.4.1 The chapters
This section explains how to pace the book’s main chapters and where to turn afterward for next steps and quick reference.
- One Chapter Daily Pace: Explain why the book recommends working through roughly one main chapter per day rather than rushing ahead, and how practice fits into that schedule.
Why it matters: A steady pace leaves room to try the commands and absorb each chapter’s ideas. - Next Steps And Reference: Describe the different purposes of chapter 27 and the appendix after the main content.
Why it matters: You can use chapter 27 for direction and the appendix when you need a reminder.
Key terms: main content, practicing, one chapter a day, Chapter 27, PowerShell cheat sheet, gotchas
1.4.2 Hands-on labs
1.4.3 Supplementary materials
This section points readers to free videos that supplement the book.
- Free supplementary video resources: Describe the book-specific help-system video and the broader collection of free PowerShell videos available through PowerShell.org.
Why it matters: These free videos offer another way to learn alongside the book.
Key terms: help system, Manning’s free content center, PowerShell.org
1.4.4 Further exploration
This section explains how Further exploration suggestions help readers go beyond topics the book covers briefly.
- Purpose of Further Exploration: Explain that some chapters only skim a technology and end with suggestions and additional resources, including free ones, for exploring it further when needed.
Why it matters: You can use these suggestions when you need more depth than a chapter provides.
Key terms: Further exploration, additional resources
1.4.5 Above and beyond
This subsection explains what “Above and beyond” sections offer and how to use them without losing focus on practical learning.
- Above and beyond sections: Explain that “Above and beyond” sections offer brief, optional explanations of why PowerShell works as it does, rather than many extra practical skills. Describe when a reader might skip them and return later.
Why it matters: You can choose whether a deeper explanation helps you now or is better saved for later.
Key terms: Above and beyond
1.5 Setting up your lab environment
This section explains how to set up a safe practice environment for the book’s PowerShell labs and what to expect across operating systems.
- Safe practice environment: Explain why practice should happen in a lab rather than a company’s production environment, and describe how many computers the book requires.
Why it matters: A separate lab lets you practice without using production systems. - Windows lab requirements: Describe the suggested Windows setup and distinguish the preinstalled Windows PowerShell from the separately installed PowerShell 7.
Why it matters: The distinction prevents you from mistaking preinstalled Windows PowerShell 5.1 for PowerShell 7. - Cross-platform lab expectations: Describe the additional editor setup and explain why some book examples may differ on macOS or Linux.
Why it matters: These expectations help you choose the right tools and recognize when an example is Windows-specific.
Key terms: lab environment, production environment, PowerShell 7.1, Windows PowerShell 5.1, Visual Studio Code, PowerShell extension, cross-platform, Get-Process
1.6 Installing PowerShell
This section shows readers how to check their PowerShell version, find official installation information, and adjust console settings for their operating system.
- PowerShell version and installation sources: Describe how to check the installed PowerShell version and where to find the latest releases and installation instructions.
Why it matters: These are the section’s starting points for checking what you have and finding installation information. - Windows console readability settings: Explain why the section recommends changing the Windows text-based console font and describe how to adjust its settings.
Why it matters: A readable, persistent console setup makes PowerShell commands easier to work with. - Non-Windows console appearance: Distinguish how the section describes launching and customizing PowerShell on non-Windows systems from using Windows console Properties.
Why it matters: It keeps readers on Linux or macOS from looking for Windows-only console settings.
Key terms: $PSVersionTable, PowerShell console, official PowerShell home page, text-based console host, Lucida fixed-width font, Properties, screen buffer, non-Windows operating systems, command line, Bash shell
1.7 Contacting us
This section points readers to places to ask PowerShell questions, find further learning resources, and give the authors feedback.
- PowerShell community resources: Describe where the section suggests asking PowerShell questions and finding resources for continued learning, and explain why the authors welcome feedback.
Why it matters: These places give you ways to get help and keep learning beyond the book.
Key terms: forums.powershell.org, powershell.org, feedback
1.8 Being immediately effective with PowerShell
The section explains why the book prioritizes practical PowerShell use before covering every detail.
- Practical First Learning Approach: Explain why the book sometimes starts with a useful PowerShell task before explaining all its theory and caveats.
Why it matters: You can follow the practical examples without assuming an early explanation is the whole story.
Key terms: immediately effective, real production environment
Where this is used later
- Not scripting, but running commands (chapter 4) · Introduces running commands without treating scripting as the starting point.
- Making commands repeatable (chapter 19) · Provides the motivation for making commands repeatable.
- PowerShell on macOS (chapter 2) · Introduces PowerShell on macOS.
- PowerShell on Linux (Ubuntu 18.04) (chapter 2) · Introduces PowerShell on Linux.
- (chapter intro) (chapter 19) · Marks the start of a chapter the section identifies as Windows-focused.
- (chapter intro) (chapter 20) · Marks the start of the other chapter the section identifies as Windows-focused.
- Lab (chapter 2) · The reader uses the practice environment for the first lab.
- Installing Visual Studio Code and the PowerShell extension (chapter 2) · The reader installs VS Code and the PowerShell extension.
Concepts explained in this chapter
- PowerShellPowerShell 3 is the third major version of the PowerShell command-line shell.
- commandA command is an executable instruction that a shell can invoke to perform an operation.
- PowerShell extensionThe PowerShell extension is a Visual Studio Code extension that adds PowerShell editing and development support.
- Visual Studio CodeVisual Studio Code is a cross-platform source-code editor with an extensible extension system.
- command-line interfaceA command-line shell is an interactive text-based interface that interprets and runs commands.
- PowerShell help systemA help system is an integrated facility that provides software documentation and assistance for discovering and understanding available commands and features.
- regular expressionA regular expression is a pattern notation for matching and processing text according to specified character sequences.
- remotingRemoting is the execution of commands or management operations on a computer or service over a network connection.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.
