Skip to content

Audit

Save history of your commands

Start logging commands

Option A - write to autogenerated file in default dir "C:\Users\$env:USERNAME\Documents\"

Start-Transcript

Option B - write to a specific file

Start-Transcript -Path "C:\logs\session.txt"

Stop logging commands

Stop-Transcript

Check Logs

cat C:\Users\$env:USERNAME\Documents\PowerShell_transcript.*.txt