<p/><br></br><p><b> Book Synopsis </b></p></br></br><p></p><p><b>Introduction </b></p> <p><b>Chapter 1. Do The Basics </b></p> <p>Plan Before you Code </p> <p>Don't Reinvent the Wheel </p> <p>Build Functions as Building Blocks </p> <p>Build Re-usable Tools </p> <p>Don't Focus Purely on Performance </p> <p>Build Pester tests </p> <p>Implement Error handling </p> <p>Build Manageable Code </p> <p>Don't Skimp on Security </p> <p>Log Script Activity </p> <p>Parameterize Everything </p> <p>Limit Script and Function Input </p> <p>Maintain Coding Standards </p> <p>Code in Context </p> <p>Return Informative Output </p> <p>Understand Your Code </p> <p>Use Version Control </p> <p>Write for Cross Platform</p> <p>Write for the Next Person </p> <p>Use a Code Editor </p> <p><b>Chapter 2. Don't Reinvent the Wheel </b></p> <p>Use Community Modules </p> <p>Leverage Others' work </p> <p><b>Chapter 3: </b><b>Use Visual Studio Code</b><br></p><p>PowerShell Integrated Scripting Environment</p><p>Using Visual studio over PowerShell ISE</p><p><b>Chapter 4. Plan Before you Code </b></p> <p>Write Comments Before Coding </p> <p>Use your Code as a Todo List </p> <p><b>Chapter 5. Create Building Blocks with Functions </b></p> <p>Write Functions with One, Single Goal </p> <p>Build Functions with Pipeline Support </p> <p>Save Commonly-Used, Interactive Functions to Your Profile </p> <p><b>Chapter 6. Parameterize Everything </b></p> Don't Hardcode. Always Use Parameters <p></p> <p>Use Parameter Sets When All Parameters Should Not be Used at Once </p> <p>Use a PSCredential Object Rather than a Separate Username and Password </p> <p><b>Chapter 7. Log Script Activity </b></p> <p>Use a Logging Function </p> <p>Clean up Verbose Messages </p> <p><b>Chapter 8. Build with Manageability in Mind </b></p> <p>DRY: Don't Repeat Yourself </p> <p>Don't Store Configuration Items in Code </p> <p>Always Remove Dead Code </p> <p><b>Chapter 9. Be Specific </b></p> <p>Use Strict Mode </p> <p>Don't Ignore Errors </p> <p>Validate Input Parameters </p> <p>Explicitly Define Parameter Types </p> <p>Enforce Mandatory Parameters </p> <p>Use the #requires Statement .</p> <p><b>Chapter 10. Write for the Next Person </b></p> <p>Give your Variables Meaningful Names </p> <p>String Substitution </p> <p>Don't use Aliases in a Script </p> <p>Put functions in Alphabetical Order in a Module </p> <p>Explain Regular Expressions with Comments </p> <p>Write Comment-Based Help </p> <p>Weigh the Difference Between Performance and Readability </p> <p><b>Chapter 11. Handle Errors Gracefully </b></p> <p>Force Hard-Terminating Errors </p> <p>Avoid Using $? </p> <p>Copy $Error[0] to your Own Variable </p> <p><b>Chapter 12. Don't Skimp on Security </b></p> <p>Sign Scripts </p> <p>Use Scriptblock Logging </p> Never Store Sensitive Information in Clear Text in Code <p></p> <p>Don't use Invoke-Expression </p> <p>Use PowerShell Constrained Language Mode </p> <p><b>Chapter 13. Stick to PowerShell </b></p> <p>Use Native PowerShell Where Possible </p> <p>Use PowerShell standard cmdlet naming </p> <p><b>Chapter 14. Build Tools </b></p> <p>Code for Portablity </p> <p>Wrap Command-Line Utilities in Functions .</p> <p>Force Functions to Return Common Object Types </p> <p>Ensure Module Functions Cover all the Verbs</p> <p><b>Chapter 15. Return Standardized, Informative Output </b></p> <p>Use Progress Bars Wisely </p> <p>Leave the Format Cmdlets to the Console </p> <p>Use Write-Verbose </p> <p>Use Write-Information </p> <p>Ensure a Command Returns One Type of Object </p> <p>Only Return Necessary Information to the Pipeline </p> <p><b>Chapter 16. Build Scripts for Speed </b></p> <p>Use an ArrayList or GenericList .NET Class when Elements Need to be Added to an Array </p> <p>Use a Regular Expression to Search Multiple String Values </p> <p>Don't use Write-Host in Bulk </p> <p>Don't use the Pipeline </p> <p>Use the .foreach() and .where() Methods . </p> <p>Use Paralle<p/><br></br><p><b> From the Back Cover </b></p></br></br>Learn to write better PowerShell code via short, example-driven tips. This book covers tips to make your PowerShell scripts faster and easier to read all while following proven best practices. Written by a six-time Microsoft MVP and one of the first Microsoft PowerShell MVPs with over a decade of PowerShell experience, Building Better PowerShell Code gives you easily digestible tips you can begin using immediately. The book starts with an overview of some of the most important tips the author can muster which segues into a deeper dive with dozens of examples throughout the book. It takes you through tips such as using community modules, writing better comments, thinking of PowerShell functions as building blocks, and more. You will also see how to use parameters the right way and how to create simple logging code to easily record script activity. <p></p>You will learn not only how to write better code, but also how to implement some mindset tricks, such as being explicit and specific with code and how to write code that reads well. You'll get into error handling and also how to make your scripts more secure. Finally, you'll examine the concept of building PowerShell tools and how to build scripts for speed. <p></p>Other tips and best practices include: <p></p><ul><li>Building Pester tests</li><li>Improving performance through parallel processing</li><li>Writing cross-platform scripts</li><li>Using filtering properly </li></ul><p>After reading this book and applying these tips, you will have an expert coding mindset and be able to build PowerShell code that's efficient, readable, and compliant with many best practices. </p><p/><br></br><p><b> About the Author </b></p></br></br>Adam Bertram is a 20+ year veteran of IT and an experienced online business professional. He's a consultant, Microsoft MVP, blogger, trainer, published author and content marketer for multiple technology companies.
Price Archive shows prices from various stores, lets you see history and find the cheapest. There is no actual sale on the website. For all support, inquiry and suggestion messagescommunication@pricearchive.us