浏览代码

Fix wix installer not using the right path

Daniel Chalmers 9 月之前
父节点
当前提交
80b8dd3898
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 1 1
      .github/actions/prepare-for-release/action.yml
  2. 1 1
      Product.wxs

+ 1 - 1
.github/actions/prepare-for-release/action.yml

@@ -29,7 +29,7 @@ runs:
         dotnet tool install --global wix --version 4.0.6
         for rid in ${{ inputs.rids }}; do
           dotnet publish ./DesktopClock/DesktopClock.csproj -o "publish/$rid" -c Release -r $rid -p:Version=${{ inputs.version }}
-          wix build Product.wxs -o "publish/$rid/Install DesktopClock ${{ inputs.version }} ${rid}.msi"
+          wix build Product.wxs -dMainExeSource="publish/$rid/DesktopClock.exe" -o "publish/$rid/Install DesktopClock ${{ inputs.version }} ${rid}.msi"
         done
 
     - uses: actions/upload-artifact@v4

+ 1 - 1
Product.wxs

@@ -48,7 +48,7 @@
   <Fragment>
     <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
       <Component Id="MainExe" Guid="2148738D-B1F4-48BD-8615-1617541C6BB3">
-        <File Id="MainExe" Name="$(var.Name).exe" Source="publish/$(var.Name).exe" />
+        <File Id="MainExe" Name="$(var.Name).exe" Source="$(var.MainExeSource)" />
       </Component>
     </ComponentGroup>
   </Fragment>