diff options
author | Brad King <brad.king@kitware.com> | 2023-04-26 19:46:11 (GMT) |
---|---|---|
committer | Jannik Alber <alber.jannik@gmail.com> | 2023-04-27 19:55:18 (GMT) |
commit | 9b0dc652ffc328394e70bf6ee015b50cfefa4125 (patch) | |
tree | 005b3e6b4a791a6deae72f327e2eb66610aa8814 /.gitlab/ci/innosetup.ps1 | |
parent | 582c17bdd24b8443f82b3da4143893741d6b1c1f (diff) | |
download | CMake-9b0dc652ffc328394e70bf6ee015b50cfefa4125.zip CMake-9b0dc652ffc328394e70bf6ee015b50cfefa4125.tar.gz CMake-9b0dc652ffc328394e70bf6ee015b50cfefa4125.tar.bz2 |
ci: Provide Inno Setup tools to some Windows CI jobs
Diffstat (limited to '.gitlab/ci/innosetup.ps1')
-rwxr-xr-x | .gitlab/ci/innosetup.ps1 | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/.gitlab/ci/innosetup.ps1 b/.gitlab/ci/innosetup.ps1 new file mode 100755 index 0000000..a7f4eb3 --- /dev/null +++ b/.gitlab/ci/innosetup.ps1 @@ -0,0 +1,20 @@ +$erroractionpreference = "stop" + +$version = "6.2.2-1" +$sha256sum = "34D5311070678617424628A88C8A7F7BE41157B1A59112F9DFDA1D7EFD4469CC" +$filename = "innosetup-$version" +$tarball = "$filename.zip" + +$outdir = $pwd.Path +$outdir = "$outdir\.gitlab" +$ProgressPreference = 'SilentlyContinue' +Invoke-WebRequest -Uri "https://cmake.org/files/dependencies/internal/$tarball" -OutFile "$outdir\$tarball" +$hash = Get-FileHash "$outdir\$tarball" -Algorithm SHA256 +if ($hash.Hash -ne $sha256sum) { + exit 1 +} + +Add-Type -AssemblyName System.IO.Compression.FileSystem +[System.IO.Compression.ZipFile]::ExtractToDirectory("$outdir\$tarball", "$outdir") +Move-Item -Path "$outdir\$filename" -Destination "$outdir\innosetup" +Remove-Item "$outdir\$tarball" |