Skip to content

Instantly share code, notes, and snippets.

@egre55
Last active December 21, 2022 00:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save egre55/816ddb91016034dcf747f4ea5f054767 to your computer and use it in GitHub Desktop.
Save egre55/816ddb91016034dcf747f4ea5f054767 to your computer and use it in GitHub Desktop.
procmon.ps1
# Simple PowerShell process monitor
while($true)
{
$process = Get-WmiObject Win32_Process | Select-Object CommandLine
Start-Sleep 1
$process2 = Get-WmiObject Win32_Process | Select-Object CommandLine
Compare-Object -ReferenceObject $process -DifferenceObject $process2
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment