Chapter 18. Debugging Scripts
After completing this chapter, you will be able to:
Use the Write-Debug cmdlet to provide detailed information from a script.
Use the Set-StrictMode cmdlet to prevent errors during development.
Understand how to work with the Windows PowerShell debugger.
Understanding debugging in Windows PowerShell
No one enjoys debugging scripts. In fact, the best debugging is no debugging. It is also true that well-written, well-formatted, well-documented, and clearly constructed Microsoft Windows PowerShell code requires less effort to debug than poorly formatted, undocumented spaghetti code. It is fair to say that debugging begins when you first open the Windows PowerShell ISE. Therefore, you might want to review Chapter 5, Chapter 6 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access