Skip to content

Instantly share code, notes, and snippets.

@KevinMarquette
Last active March 1, 2016 18:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KevinMarquette/f81b6f0a54c9df650c22 to your computer and use it in GitHub Desktop.
Save KevinMarquette/f81b6f0a54c9df650c22 to your computer and use it in GitHub Desktop.
<#
.Example
.\HadoopVSPowershell.ps1
.Author
@KevinMarquette
.Notes
You may need to [GC]::Collect() after this because it uses a lot of RAM
#>
[cmdletbinding()]
param([string]$Path = (Get-Location))
process
{
$count = @{}
ls $Path -include *.pgn -recurse | Get-Content | ?{$_ -match 'Result '} | %{$count[$_]+=1}
Write-Output $count
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment