Run Experiments in PowerShell with PSScriptPad Scratches

Image Description

Daily PowerShell #28

Daily PowerShell PowerShell Pro Tools

November 13, 2021

PSScriptPad is a single-file, IDE for PowerShell. This blog post outlines how to use the Scratch Pad feature.

Creating a Scratch

The Scratch Pad can be opened by clicking the Open Scratch Pad Button in PSScriptPad. Scratches do not require saving and can be executed right away. Whenever a scratch is executed, the input and output will be saved to the scratch database. Scratches can then be reviewed later.

Viewing Scratches

Scratches can be viewed within the Scratches tab. At the top of the dialog, you will find the list of previous scratches. PSScriptPad will retain the last 100 scratches. Each scratch indicates the command run, the number of objects output, and the execution time.

Clicking on a scratch will display the scratch input. You can see it listed below the list of scratches.

You will also be able to view the scratch output. Scratch output is saved as CLIXML and can be viewed in the tree view below the input. You can use the tree view to traverse through the objects returned.