Skip to content

Commit

Permalink
Pinned Semver version to ensure we have consistent dependency for builds
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyButland committed Nov 6, 2024
1 parent ce0e580 commit 3ea4e37
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions ps/GetUmbracoBuildEnv.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ $ubuild.DefineMethod("GetUmbracoBuildEnv",
if (-not (test-path $semver))
{
Write-Host "Download Semver..."
$params = "-OutputDirectory", $scriptTemp, "-Verbosity", "quiet", "-Source", $nugetsource
$params = "-Version", "2.3.0", "-OutputDirectory", $scriptTemp, "-Verbosity", "quiet", "-Source", $nugetsource
&$nuget install semver @params
$dir = ls "$scriptTemp\semver.*" | sort -property Name -descending | select -first 1
$file = "$dir\lib\net452\Semver.dll"
Expand Down Expand Up @@ -233,7 +233,7 @@ $ubuild.DefineMethod("GetUmbracoBuildEnv",
$vsVersions = new-object System.Collections.Generic.List[System.Version]

Write-Host "Finding MSbuild.exe"

# parse vswhere output
$params = @()
if ($options.VsPreview) { $params += "-prerelease" }
Expand All @@ -254,9 +254,9 @@ $ubuild.DefineMethod("GetUmbracoBuildEnv",
}
}
if ($vsIx2 -ge 0) {

Write-Host "Detected VS version " $vsVersion.Major

$vsPath = $vsPaths[$vsIx2]

if ($vsVersion.Major -gt 16) {
Expand All @@ -282,7 +282,7 @@ $ubuild.DefineMethod("GetUmbracoBuildEnv",
MsBuild = "$msBuild\MsBuild.exe"
ToolsVersion = $toolsVersion
}

Write-Host "Using MsBuild.exe in $msBuild\MsBuild.exe"
}
}
Expand Down

0 comments on commit 3ea4e37

Please sign in to comment.