Skip to content

Commit

Permalink
Trying to convert to WiX CLI
Browse files Browse the repository at this point in the history
  • Loading branch information
iadgovuser29 committed Feb 8, 2024
1 parent 575d2a6 commit 396cff8
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 10 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/dotnet_provisioner_unit_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,35 @@ jobs:
fi
echo "::set-output name=result::$result"
more $logName
- name: Install packaging tools
working-directory: HIRS_Provisioner.NET/hirs
run: |
dotnet tool install --global dotnet-deb
dotnet tool install --global dotnet-rpm
dotnet tool install --global wix
- name: Run packaging tools
if: contains(matrix.os, 'ubuntu')
working-directory: HIRS_Provisioner.NET/hirs
run: |
dotnet deb -r linux-x64 -c Release
dotnet rpm -r linux-x64 -c Release
- name: Run packaging tools
if: contains(matrix.os, 'windows')
working-directory: HIRS_Provisioner.NET/hirs
run: |
dotnet deb -r linux-x64 -c Release
dotnet rpm -r linux-x64 -c Release
dotnet build HIRS_Provisioner.NET.wixproj -r win-x64 -c Release
- name: Setup tmate session on error
if: ${{ failure() }}
uses: mxschmitt/action-tmate@v3
timeout-minutes: 30 # The ssh session will be available for 2 minutes.
with:
limit-access-to-actor: true # Only the person who pushed can access- with a github-registered key.

- name: Upload Logs Ubuntu
uses: actions/upload-artifact@v2
Expand Down
11 changes: 1 addition & 10 deletions HIRS_Provisioner.NET/hirs/Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,10 @@
</PropertyGroup>
<Message Text="Set installed directory prefix to $(PREFIX)." Importance="high" />
</Target>
<Target Name="RenameBeforePublishWindows" BeforeTargets="SetWixPath" Condition="$(RuntimeIdentifier.Contains('win'))">
<Target Name="RenameBeforePublishWindows" BeforeTargets="CreatePackageProperties" Condition="$(RuntimeIdentifier.Contains('win'))">
<Move SourceFiles="$(OUTDIR)publish\$(AssemblyName).exe" DestinationFiles="$(OUTDIR)publish\tpm_aca_provision.exe" />
<Message Text="Renamed exe binary file." Importance="high" />
</Target>
<Target Name="SetWixPath" BeforeTargets="Msi">
<PropertyGroup>
<ProductSourceFilePath>$(MSBuildThisFileDirectory)\Resources\Product.wxs</ProductSourceFilePath>
<WixInstallPath>$(NuGetPackageRoot)wix\3.11.2\tools\</WixInstallPath>
<Heat>$(WixInstallPath)heat.exe</Heat>
<Candle>$(WixInstallPath)candle.exe</Candle>
<Light>$(WixInstallPath)light.exe</Light>
</PropertyGroup>
</Target>
<Target Name="DeletePDB" AfterTargets="RenameBeforePublishLinux;RenameBeforePublishWindows">
<ItemGroup>
<PDBToDelete Include="$(PublishDir)*.pdb"/>
Expand Down
5 changes: 5 additions & 0 deletions HIRS_Provisioner.NET/hirs/HIRS_Provisioner.NET.wixproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<Project Sdk="WixToolset.Sdk/4.0.4">
<ItemGroup>
<Compile Include="Resources/Product.wxs" />
</ItemGroup>
</Project>

0 comments on commit 396cff8

Please sign in to comment.