Added sketchup to download and update hash check

This commit is contained in:
2024-03-25 10:52:23 +00:00
parent 666a869f07
commit bb2e5986fd

View File

@@ -100,6 +100,11 @@ function DownloadFiles {
FileName = "simulation.zip"
Hash = "2327c15c390d53d4d5929a1a53acea566c8fba42"
},
@{
Url = "https://git.justw.tf/Lightemerald/setup-script/raw/branch/main/Setup%20files/googlesketchupwen.exe"
FileName = "googlesketchupwen.exe"
Hash = "f0628e6f05241f91e4f36d6be3b8685a408ad12b"
},
@{
Url = "https://git.justw.tf/Lightemerald/setup-script/raw/branch/main/Setup%20files/RobotProg.zip"
FileName = "RobotProg.zip"
@@ -133,7 +138,7 @@ function DownloadFiles {
if (-not (Test-Path -Path $filePath -PathType Leaf)) {
Invoke-WebRequest -Uri $fileInfo.Url -OutFile $filePath
}
if ((Get-FileHash -Path $filePath).Hash -ne $fileInfo.Hash) {
if ((Get-FileHash -Path $filePath -Algorithm SHA1).Hash -ne $fileInfo.Hash) {
Invoke-WebRequest -Uri $fileInfo.Url -OutFile $filePath
}
}