Use Stop-Transcript to record only input

Viewed 40

I want to use "Start-Transcript" command to record only the input in the VS-Code terminal in windows. Currently it records both input as well as the output. Also is there any better way to record just the input in the VS code terminal?

1 Answers

Use Get-History to obtain a list of all command lines that were submitted in the current session.

(Get-History).CommandLine outputs just the command lines, as strings.

Related