For online information and ordering of these and other Manning books, please visit www.manning.com. The publisher offers discounts on these books when ordered in quantity.
Manning Publications Co.
2022 by Manning Publications Co. All rights reserved.
No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by means electronic, mechanical, photocopying, or otherwise, without prior written permission of the publisher.
Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in the book, and Manning Publications was aware of a trademark claim, the designations have been printed in initial caps or all caps.
Recognizing the importance of preserving what has been written, it is Mannings policy to have the books we publish printed on acid-free paper, and we exert our best efforts to that end. Recognizing also our responsibility to conserve the resources of our planet, Manning books are printed on paper that is at least 15 percent recycled and processed without the use of elemental chlorine.
Front matter
foreword
Sitting down to write this foreword, my first thought was, Wow, theres a lot to unpack here. My own time with PowerShell started in 2005, about a year before the shell was unleashed at TechEd Barcelona 2006. Learn Windows PowerShell in a Month of Lunches, the progenitor of this book, was far from my first PowerShell tome. Jeff Hicks and I wrote three editions of Windows PowerShell: TFM with SAPIEN Technologies first. After those, I actually made a decision, if you can imagine it, to not write any more PowerShell books! But I quickly came to realize that the existing selection of PowerShell bookswell over a dozen by thenwas missing a major audience need. The books of the time were teaching PowerShell as a programming language, aiming for the fairly large audience of VBScript coders that existed at the time. But PowerShell itself was aiming for a far larger and broader audience: nonprogrammers.
Thats when I took the narratives Id been using in live PowerShell classes and started constructing a new book: one that wouldnt head directly to control-of-flow statements by chapter 3, and one that would really focus on a best-fit sequence of teaching to make learning PowerShell as easy as possible. I wanted to make, and keep, a promise: give me an hour a day for a month, and Ill make you functionally useful in PowerShell.
Month of Lunches, as a book series, had a bit of a rough road. Book publishers operate on razor-thin margins, and launching a new series consumes a lot of resources. A different publisher originally decided to give the series a shot but backed out at the last minute. Manningin what I hope has been a fantastic decision for themstepped up and said, Lets do it. We developed a new cover art concept that was a radical departure from the companys norm, showing how willing they were to think creatively about this new series.
Learn Windows PowerShell in a Month of Lunches was a solid hit, becoming one of the best-selling PowerShell books in the world. Its been translated into a number of different languages, and for many people it was their first exposure to PowerShell. Ive heard from thousands of people how the book helped them break into the world of PowerShell. For many, it was their first PowerShell learning experience. For most, it wasnt their last, but Im proud that so many people trusted Jeff and me to get them started.
When Microsoft finally made PowerShell open source (!!!!) and cross-platform (!!!!!!!), we knew it would be time for a new Month of Lunches bookone that addressed PowerShell instead of just Windows PowerShell.
But by that point, Jeff and I were a little burned out on writing. My own career was moving in a different directionId accepted a VP role at my company, and I knew Id be hard pressed to keep up with PowerShells rapidly changing and expanding world. My final book, Shell of an Idea: The Untold History of PowerShell, was in many ways a love letter to the community and product team that had been supporters and friends for more than a decade. It told the stories of how PowerShell only barely managed to come to life, and I knew as I wrote it that I wouldnt have the time to write any more about PowerShells future.
Thats why Im so glad that the authors of this volume stepped in. The PowerShell community in general is full of incredibly generous people, always willing to answer a question and help you out. Stepping away, for me, also meant stepping away from PowerShell.org, the website I cofounded, and the nonprofit that backed it. It meant stepping away from PowerShell + DevOps Global Summit, a conference I first financed on my American Express card. But the PowerShell community stepped up as they almost always do: new people agreed to keep the organization not only going, but also growing. James Petty, one of this books coauthors, is one of those folks, and Im forever grateful to him and his team for keeping the community spirit alive.
This book largely builds on the narrative that I created for the first Month of Lunches title and that Jeff Hicks and I refined through three editionsalong with Learn PowerShell Scripting in a Month of Lunches, a book thats as relevant today as it was when we first wrote it. But this book breaks out of the Windows operating system and treats PowerShell as a true global citizen: youll find examples applicable whether youre running PowerShell on Windows, Linux, or macOSa huge undertaking for these authors, given the stark differences between those operating systems.
I remain incredibly grateful to the PowerShell community. Theyve made me feel welcomed, appreciated, and valuablesomething I hope everyone can experience at some point. Its a community I encourage you to explore, via PowerShell.org or the many other volunteer-driven websites, GitHub repos, Twitter accounts, and other outlets. Youll be glad you did.