clear-historyDelete entries from the PowerShell session command history. Note:
clhycan be used as an alias forClear-History. More information: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/clear-history.
Clear-History
Clear-History -CommandLine "{{command}}"
Clear-History -CommandLine {{"command1", "command2", ...}}
Clear-History -Id {{id_number}}
Clear-History -Id {{id1, id2, ...}}
Clear-History -Id ({{start_id}}..{{end_id}})
Clear-History -WhatIf
Clear-History -Confirm