O'Reilly logo

Windows PowerShell™ 3.0 Step by Step by Ed Wilson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Debugging the script

The debugging features of Windows PowerShell 3.0 make the use of the Set-PSDebug cmdlet seem rudimentary or even cumbersome. Once you are more familiar with the debugging features of Windows PowerShell 3.0, you may decide to look no longer at the Set-PSDebug cmdlet. Several cmdlets enable debugging from the Windows PowerShell console and from the Windows PowerShell ISE.

The debugging cmdlets appear in Table 18-2.

Table 18-2. Windows PowerShell debugging cmdlets

Cmdlet name

Cmdlet function

Set-PSBreakpoint

Sets breakpoints on lines, variables, and commands

Get-PSBreakpoint

Gets breakpoints in the current session

Disable-PSBreakpoint

Turns off breakpoints in the current session

Enable-PSBreakpoint

Reenables breakpoints ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required