diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index af16cb0..b01ef0a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,16 +6,9 @@ on: - "v*.*.*" jobs: - release-artifacts: - name: Upload prebuilt binaries on GitHub - runs-on: ${{ matrix.os }} - strategy: - matrix: - include: - - os: windows-latest - artifact: "nuance.exe" - - os: ubuntu-latest - artifact: "nuance" + release-linux: + name: Build binaries (linux) and publish on crates.io + runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v2 @@ -28,16 +21,42 @@ jobs: profile: minimal components: rust-docs - name: Install gtk - if: matrix.os == 'ubuntu-latest' run: sudo apt update && sudo apt install libgtk-3-dev + - name: Install Vulkan SDK + run: | + wget -qO - https://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add - + sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.2.176-focal.list https://packages.lunarg.com/vulkan/1.2.176/lunarg-vulkan-1.2.176-focal.list + sudo apt update + sudo apt install vulkan-sdk - name: Build release run: cargo build --release - name: Upload release artifact uses: softprops/action-gh-release@v1 with: - files: target/release/${{ matrix.artifact }} + files: target/release/nuance env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Publish release on crates.io - if: matrix.os == 'windows-latest' run: cargo publish --token ${{ secrets.CRATES_IO_TOKEN }} + release-windows: + name: Build binaries (windows) + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - uses: seanmiddleditch/gha-setup-ninja@master + - name: Install rust stable + uses: actions-rs/toolchain@v1 + with: + toolchain: stable + default: true + profile: minimal + components: rust-docs + - name: Build release + run: cargo build --release + - name: Upload release artifact + uses: softprops/action-gh-release@v1 + with: + files: target/release/nuance.exe + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}