Skip to content

Commit

Permalink
Try directly in the yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
neilenns committed Dec 7, 2023
1 parent 5534f19 commit 2dcdce0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 15 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ jobs:

- name: Downgrade NSIS
shell: pwsh
run: .\Build\downgrade_nsis.ps1
run: |
Invoke-WebRequest https://netcologne.dl.sourceforge.net/project/nsis/NSIS%203/3.04/nsis-3.04-setup.exe -OutFile C:\WINDOWS\Temp\nsis-3.04-setup.exe
Invoke-Expression "& C:\WINDOWS\Temp\nsis-3.04-setup.exe /S"
makensis.exe /VERSION
- name: Restore NuGet packages
working-directory: ${{env.GITHUB_WORKSPACE}}
Expand Down
17 changes: 3 additions & 14 deletions Build/downgrade_nsis.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,11 @@
################################################################################

$NsisVersion = "3.04"
$downloadUrl = "https://netcologne.dl.sourceforge.net/project/nsis/NSIS%203/${NsisVersion}/nsis-${NsisVersion}-setup.exe"
$downloadPath = "C:\WINDOWS\Temp\nsis-${NsisVersion}-setup.exe"

Write-Host "Downloading NSIS version $NsisVersion"
$response = Invoke-WebRequest $downloadUrl -OutFile $downloadPath -PassThru
Write-Host "Downloaded $($response.BaseResponse.ContentLength) bytes"

Write-Host "Installing NSIS version $NsisVersion"
$installOutput = Invoke-Expression "& $downloadPath /S 2>&1"
Write-Host "Install Output: $installOutput"
Invoke-WebRequest "https://netcologne.dl.sourceforge.net/project/nsis/NSIS%203/${NsisVersion}/nsis-${NsisVersion}-setup.exe" -OutFile "C:\WINDOWS\Temp\nsis-${NsisVersion}-setup.exe"
Invoke-Expression "& C:\WINDOWS\Temp\nsis-${NsisVersion}-setup.exe /S"

$NsisPath = "${env:ProgramFiles(x86)}\NSIS\"
Write-Host "Adding NSIS to the PATH"
Add-MachinePathItem $NsisPath
$env:Path = Get-MachinePath

Write-Host "Checking NSIS version"
$versionOutput = makensis.exe /VERSION
Write-Host "NSIS Version: $versionOutput"
makensis.exe /VERSION

0 comments on commit 2dcdce0

Please sign in to comment.