Merge pull request #40596 from neikeq/fix-msbuild-restore-not-called

C#: Fix restore not called when building game projects
This commit is contained in:
Rémi Verschelde 2020-07-22 14:47:38 +02:00 committed by GitHub
commit 72d449b53e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -118,9 +118,14 @@ namespace GodotTools.Build
string arguments = string.Empty;
if (buildTool == BuildTool.DotnetCli)
arguments += "msbuild "; // `dotnet msbuild` command
arguments += "msbuild"; // `dotnet msbuild` command
arguments += $@"""{buildInfo.Solution}"" /t:{string.Join(",", buildInfo.Targets)} " +
arguments += $@" ""{buildInfo.Solution}""";
if (buildInfo.Restore)
arguments += " /restore";
arguments += $@" /t:{string.Join(",", buildInfo.Targets)} " +
$@"""/p:{"Configuration=" + buildInfo.Configuration}"" /v:normal " +
$@"""/l:{typeof(GodotBuildLogger).FullName},{GodotBuildLogger.AssemblyPath};{buildInfo.LogsDirPath}""";