Skip to content

Commit

Permalink
Need ruby to run tests
Browse files Browse the repository at this point in the history
  • Loading branch information
joshcooper committed Nov 22, 2023
1 parent 74e3f81 commit 843191a
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,6 @@ jobs:
GITHUB_TOKEN: ${{ github.token }}
shell: pwsh
run: |
$DotNetInstallationInfo = Get-ChildItem -Path 'HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP' -Recurse
$InstalledDotNetVersions = $DotNetInstallationInfo | Get-ItemProperty -Name 'Version' -ErrorAction SilentlyContinue
$InstalledVersionNumbers = $InstalledDotNetVersions | ForEach-Object {$_.Version -as [System.Version]}
$Installed3Point5Versions = $InstalledVersionNumbers | Where-Object {$_.Major -eq 3 -and $_.Minor -eq 5}
$DotNet3Point5IsInstalled = $Installed3Point5Versions.Count -ge 1
Write-Output $DotNet3Point5IsInstalled
# The mingw 5.2 package requires chocolatey 1.4, so delete 2.x
Remove-Item -Path C:\ProgramData\chocolatey\ -Recurse -Force
Expand All @@ -51,6 +44,7 @@ jobs:
choco install -y pl-curl-x64 -Version 7.46.0.1 -source https://www.myget.org/F/puppetlabs
choco install -y pl-zlib-x64 -Version 1.2.8.1 -source https://www.myget.org/F/puppetlabs
choco install -y pester -Version 4.10.1
choco install -y ruby -Version 3.1.3.1
# And our library dependencies
gh release download -R puppetlabs/leatherman $env:LEATHERMAN_VERSION --pattern "leatherman.7z"
Expand All @@ -66,16 +60,14 @@ jobs:
run: |
# Intentionally excluding some preinstalled components that conflict with our
# ancient build tooling and dependencies: Git (due to sh.exe), mingw64, cmake, OpenSSL
#
# Include Ruby and Powershell for unit tests
$oldpath = $env:PATH.Split(';')
$newpath = $oldpath | Where-Object { $_ -NotLike 'C:\Program Files\Git\*' -and $_ -NotLike 'C:\mingw64\*' -and $_ -NotLike 'C:\Program Files\CMake\*' -and $_ -NotLike 'C:\Program Files\OpenSSL\*' }
$diffpath = Compare-Object -ReferenceObject $oldpath -DifferenceObject $newpath -PassThru
Write-Output "Deleted: " $diffpath
$env:PATH = $newpath -Join ';'
# Prepend our tools
$env:PATH = "C:\tools\pl-build-tools\bin;C:\tools\mingw64\bin;$env:PATH"
# Prepend our tools and ruby
$env:PATH = "C:\tools\pl-build-tools\bin;C:\tools\mingw64\bin;C:\tools\Ruby31\bin;$env:PATH"
cmake -G "MinGW Makefiles" -DCMAKE_TOOLCHAIN_FILE="C:\tools\pl-build-tools\pl-build-toolchain.cmake" -DCMAKE_PREFIX_PATH="C:\tools\leatherman;C:\tools\cpp-pcp-client;C:\tools\cpp-hocon" -DCMAKE_INSTALL_PREFIX=C:\tools -DBOOST_STATIC=ON .
mingw32-make install
Expand Down

0 comments on commit 843191a

Please sign in to comment.