Skip to content

Commit

Permalink
Build Windows installer using cargo-wix.
Browse files Browse the repository at this point in the history
  • Loading branch information
martinling committed Jul 3, 2024
1 parent 828d667 commit f2839aa
Show file tree
Hide file tree
Showing 2 changed files with 297 additions and 2 deletions.
24 changes: 22 additions & 2 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ jobs:
run: brew install gtk4 pkg-config
if: matrix.os == 'macos-latest'

- name: Install cargo-wix (Windows)
uses: taiki-e/cache-cargo-install-action@v2
with:
tool: cargo-wix
if: matrix.os == 'windows-latest'

- name: Install dependencies (Windows)
uses: lukka/run-vcpkg@v11
with:
Expand Down Expand Up @@ -98,10 +104,24 @@ jobs:
with:
run: cargo test

- uses: actions/upload-artifact@v2
- name: Build installer (Windows)
run: cargo wix --no-build --nocapture -v
if: matrix.os == 'windows-latest'

- name: Upload binary
uses: actions/upload-artifact@v2
with:
name: Packetry ${{ matrix.os }}
name: Binary for ${{ matrix.os }}
path: |
target/release/packetry
target/release/packetry.exe
if-no-files-found: error

- name: Upload installer (Windows)
uses: actions/upload-artifact@v2
with:
name: Windows installer
path: |
target/wix/*.msi
if-no-files-found: error
if: runner.os == 'Windows'
Loading

0 comments on commit f2839aa

Please sign in to comment.