Itiviti/gradle-msbuild-plugin

parameters.RestorePackages.config appears to be ignored

ObsidianDoom opened this issue · 1 comments

Microsoft (R) Build Engine version 16.10.2+857e5a733 for .NET Framework
Gradle 7.0.2

I have an ASP.NET project in the solution that cannot convert to package reference so I need to pass in RestorePackagesConfig - but this seems to be ignored and packages are not restored and build fails. Is the syntax incorrect (below) or is that property not supported ?

plugins {
id 'com.ullink.msbuild' version '3.13'
}

tasks.register('windowsBuild',com.ullink.Msbuild) {
println("Windows Build requested for ${project.displayName}")
solutionFile = 'MySolution.sln'
configuration = 'Release'
targets = ['Clean', 'Restore', 'Rebuild']
parameters.RestorePackagesConfig = true
}

The non ASP.NET projects restore from nuget correctly. If I run msbuild in command line (non gradle plugin) -the packages are restored

hi @Lizalex-Systems

for restoring packages, please use https://github.com/Itiviti/gradle-nuget-plugin, it has a nugetRestore task that you could leverage for that purpose