We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents c0437de + 6d47c36 commit ce0d04dCopy full SHA for ce0d04d
rsCommon.psm1
@@ -515,4 +515,31 @@ Function Unlock-Credentials
515
}
516
517
return $credHT
518
+}
519
+Function Test-rsHash
520
+{
521
+ param (
522
+ [String] $file,
523
+ [String] $hash
524
+ )
525
+ if ( !(Test-Path $hash) ){
526
+ return $false
527
+ }
528
+ if( (Get-FileHash $file).hash -eq (Import-Csv $hash).hash){
529
+ return $true
530
531
+ if( (Get-FileHash $file).hash -eq (Import-Csv $hash)){
532
533
534
+ else {
535
536
537
538
+Function Set-rsHash
539
540
541
542
543
544
+ Set-Content -Path $hash -Value (Get-FileHash -Path $file | ConvertTo-Csv)
545
0 commit comments