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 ...