Skip to content

Instantly share code, notes, and snippets.

@t94j0
Created July 26, 2024 22:07
Show Gist options
  • Save t94j0/3b783204160cd354a1a60d87ca26b523 to your computer and use it in GitHub Desktop.
Save t94j0/3b783204160cd354a1a60d87ca26b523 to your computer and use it in GitHub Desktop.
You need it every once in a while
Get-ChildItem -Recurse -File | Select-Object @{Name="FileName";Expression={$_.Name}}, @{Name="MD5";Expression={(Get-FileHash $_.FullName -Algorithm MD5).Hash}}, @{Name="SHA256";Expression={(Get-FileHash $_.FullName -Algorithm SHA256).Hash}} | Export-Csv -Path "FileHashes.csv" -NoTypeInformation; Import-Csv "FileHashes.csv" | Format-Table -AutoSize
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment