Commit 2e133313 authored by Archit Tamarapu's avatar Archit Tamarapu
Browse files

[fix] new version of powershell script that can be called from any directory

parent 937816f4
Loading
Loading
Loading
Loading
Loading
+9 −4
Original line number Diff line number Diff line
@@ -27,11 +27,16 @@
#   the United Nations Convention on Contracts on the International Sales of Goods.

param(
    [Parameter(Mandatory)]
    [String]$in_dir,
    [Parameter(Mandatory)]
    [String]$out_file
)

(Get-FileHash .\[cFH][aO][tA]*\c*\*.wav -Algorithm MD5 | Out-String -Width 9999) |
ForEach-Object { $_.replace( -join ((Get-Location) , "\"), ".\") } |
ForEach-Object { $_ -replace (" ", "") } |
Out-File -Encoding utf8 $out_file
 No newline at end of file
(Get-ChildItem $in_dir -Recurse | Where-Object { $_.Name -like '*c??.wav' }) | 
ForEach-Object { 
    $name = $_.Name
    $hash = (Get-FileHash $_.FullName -Algorithm MD5).Hash

    "$name $hash" >> $out_file
} 
 No newline at end of file