Skip to content

Commit de335ae

Browse files
committed
Update build.ps1 to explicitly restore packages for the solution before building the project
1 parent 23cc13e commit de335ae

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

build/build.ps1

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,10 @@ If ($NoDocs -and -not $Debug) {
2929
}
3030

3131
# build the main project
32+
$nuget = '..\src\.nuget\NuGet.exe'
3233
$msbuild = "$env:windir\Microsoft.NET\Framework64\v4.0.30319\msbuild.exe"
3334

35+
&$nuget 'restore' $SolutionPath
3436
&$msbuild '/nologo' '/m' '/nr:false' '/t:rebuild' "/p:Configuration=$SolutionBuildConfig" "/p:Platform=Mixed Platforms" "/p:VisualStudioVersion=$VisualStudioVersion" $SolutionPath
3537
if ($LASTEXITCODE -ne 0) {
3638
$host.ui.WriteErrorLine('Build failed, aborting!')
@@ -55,4 +57,4 @@ if (-not (Test-Path 'nuget')) {
5557
mkdir "nuget"
5658
}
5759

58-
..\src\.nuget\NuGet.exe 'pack' '..\src\corelib\corelib.nuspec' '-OutputDirectory' 'nuget' '-Prop' "Configuration=$BuildConfig" '-Version' "$Version" '-Symbols'
60+
&$nuget 'pack' '..\src\corelib\corelib.nuspec' '-OutputDirectory' 'nuget' '-Prop' "Configuration=$BuildConfig" '-Version' "$Version" '-Symbols'

0 commit comments

Comments
 (0)