Created
September 25, 2020 16:27
-
-
Save kilasuit/621d4249e6fd3b7b75b54d9b412dab1c to your computer and use it in GitHub Desktop.
PSReadline no keys/secrets/tokens
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Set-PSReadLineOption -AddToHistoryHandler { | |
param([string]$line) | |
$sensitive = "password|asplaintext|token|key|secret" | |
return ($line -notmatch $sensitive) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment