From e6577ade652f9be93fb19c6778bf3d8da80f997e Mon Sep 17 00:00:00 2001 From: Markus Fleschutz Date: Wed, 1 Sep 2021 09:23:25 +0200 Subject: [PATCH] Improve output of publish-to-ipfs.ps1 --- Scripts/publish-to-ipfs.ps1 | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Scripts/publish-to-ipfs.ps1 b/Scripts/publish-to-ipfs.ps1 index 96e511f5..70f9993d 100755 --- a/Scripts/publish-to-ipfs.ps1 +++ b/Scripts/publish-to-ipfs.ps1 @@ -18,25 +18,29 @@ try { $StopWatch = [system.diagnostics.stopwatch]::startNew() + "" + "Step 1/3: Searching for IPFS executable..." & ipfs --version if ($lastExitCode -ne "0") { throw "Can't execute 'ipfs' - make sure IPFS is installed and available" } if (test-path "$Files" -pathType container) { - "Publishing folder $Files/ to IPFS..." + "" + "Step 2/3: Publishing folder $Files/ to IPFS..." [int]$Count = 1 & ipfs add -r "$Files" > $HashList - echo "Calculating digital forensics hashes to $DF_HASHES ..." + "" + echo "Step 3/3: Calculating digital forensics hashes to $DF_HASHES ..." & nice hashdeep -c md5,sha1,sha256 -r -d -l -j 1 "$Files" > $DF_Hashes } else { $FileList = (get-childItem "$Files") [int]$Count = $FileList.Count foreach ($File in $FileList) { if (test-path "$Files" -pathType container) { - "Publishing folder $File/ to IPFS..." + "Step 2/3: Publishing folder $File/ to IPFS..." & ipfs add -r "$File" >> $HashList } else { - "Publishing file $File to IPFS..." + "Step 2/3: Publishing file $File to IPFS..." & ipfs add "$File" >> $HashList } }