Skip to content

Commit

Permalink
Handle missing attribute DeletePath/@order
Browse files Browse the repository at this point in the history
  • Loading branch information
nirbar committed Jun 5, 2024
1 parent efe623d commit 26c8266
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/github-actions-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
psw_wix_version:
description: 'Custom WiX version'
required: true
default: '3.15.0-a61'
default: '3.15.0-a62'
type: string

jobs:
Expand Down
7 changes: 7 additions & 0 deletions PanelSwWixExtension/PanelSwWixCompiler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5231,6 +5231,13 @@ private void ParseDeletePath(XmlNode node)
case "Condition":
condition = Core.GetAttributeValue(sourceLineNumbers, attrib);
break;
case "Order":
order = Core.GetAttributeIntegerValue(sourceLineNumbers, attrib, -1000000000, 1000000000);
if (order < 0)
{
order += int.MaxValue;
}
break;

default:
Core.UnexpectedAttribute(sourceLineNumbers, attrib);
Expand Down
5 changes: 5 additions & 0 deletions PanelSwWixExtension/Xsd/PanelSwWixExtension.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -1568,6 +1568,11 @@ Delete folder or file specified by a path. DeletePath entries are processed in o
<xs:documentation>If a lock prevents file removal then defer the removal to after reboot. Default is yes.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="Order" use="optional" type="xs:int" default="0">
<xs:annotation>
<xs:documentation><![CDATA[Order of execution, defaults to line number. Elements with explicit order field will be executed before elements with implicit order. Negative Order values will be executed last in increasing order. For example, Order="-1" will be executed last, after Order="-2"]]></xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
Expand Down
2 changes: 1 addition & 1 deletion TidyBuild.custom.props
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
<Import Project="$(MSBuildThisFileDirectory)TidyBuild.user.props" Condition="Exists('$(MSBuildThisFileDirectory)TidyBuild.user.props')"/>
<PropertyGroup>
<FullVersion>3.11.1</FullVersion>
<FullVersion>3.11.2</FullVersion>
<FullVersion Condition=" '$(GITHUB_RUN_NUMBER)'!='' ">$(FullVersion).$(GITHUB_RUN_NUMBER)</FullVersion>
<ProductName>PanelSwWixExtension</ProductName>
<Manufacturer>Panel::Software</Manufacturer>
Expand Down

0 comments on commit 26c8266

Please sign in to comment.