Created
May 26, 2021 15:21
-
-
Save JohnL4/ae568e0ecc27f7a213f243ab0cf6289e to your computer and use it in GitHub Desktop.
awk | sort -unique in PowerShell
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
cat scheduled-task-2021-05-25.log ` | |
| sls 'Probe foo_.*' ` | |
| % {$_.Matches[0].Captures[0].Value} ` | |
| sort -uniq | |
<# | |
Matches is array of matches in line (could be multiple, for repeated occurrences of the pattern). | |
Groups is regexp capture groups, [0] is entire matched string (I guess) | |
#> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment