@joebigelow / wix / commits / cec50194

Extract running wix.exe in task to WixExeBaseTask class

Rob Mensching committed Jan 8, 2022 at 07:21 UTC cec50194881e99d1f3ef1c8a2537e2eb0c124d75
3 files changed +14 -4
src/wix/WixToolset.BuildTasks/WixBuild.cs
+1 -3
@@ -9,7 +9,7 @@ namespace WixToolset.BuildTasks
9 /// <summary>
10 /// An MSBuild task to run the WiX compiler.
11 /// </summary>
12 - public sealed partial class WixBuild : ToolsetTask
12 + public sealed partial class WixBuild : WixExeBaseTask
13 {
14 public string[] Cultures { get; set; }
15
@@ -72,8 +72,6 @@ namespace WixToolset.BuildTasks
72
73 public string AdditionalCub { get; set; }
74
75 - protected override string ToolName => "wix.exe";
76 -
75 protected override void BuildCommandLine(WixCommandLineBuilder commandLineBuilder)
76 {
77 commandLineBuilder.AppendTextUnquoted("build");
src/wix/WixToolset.BuildTasks/WixExeBaseTask.cs new
+12
@@ -0,0 +1,12 @@
1 +// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2 +
3 +namespace WixToolset.BuildTasks
4 +{
5 + /// <summary>
6 + /// An MSBuild task to run WiX to update cabinet signatures in a MSI.
7 + /// </summary>
8 + public abstract partial class WixExeBaseTask : ToolsetTask
9 + {
10 + protected override string ToolName => "wix.exe";
11 + }
12 +}
src/wix/WixToolset.BuildTasks/WixExeBaseTask_Inproc.cs renamed
+1 -1
@@ -10,7 +10,7 @@ namespace WixToolset.BuildTasks
10 using WixToolset.Core.WindowsInstaller;
11 using WixToolset.Extensibility.Services;
12
13 - public partial class WixBuild
13 + public abstract partial class WixExeBaseTask
14 {
15 protected override string TaskShortName => "WIX";
16