From cc19b7f6823085b1164fb0d647ba94f337b9de16 Mon Sep 17 00:00:00 2001 From: Bene <37740907+Nereuxofficial@users.noreply.github.com> Date: Tue, 6 Dec 2022 19:57:38 +0100 Subject: [PATCH] Fixed release.yml --- .github/workflows/ci.yml | 1 - .github/workflows/release.yml | 93 +++++++++++++++++------------------ 2 files changed, 46 insertions(+), 48 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ce8d618..ca9a804 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,7 +10,6 @@ env: CARGO_TERM_COLOR: always jobs: - build: strategy: matrix: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 93593f7..34e78b3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,3 @@ -# .github/workflows/release.yml name: Release on: @@ -11,49 +10,49 @@ jobs: matrix: os: [ windows-2019, ubuntu-latest ] toolchain: [ nightly ] - runs-on: ${{ matrix.os }} - steps: - - name: Checkout - uses: actions/checkout@v2 - - - name: Get Rust toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: ${{ matrix.toolchain }} - override: true - - - name: Install alsa - if: ${{ runner.os == 'Linux' }} - run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev - - - name: Install udev - if: ${{ runner.os == 'Linux' }} - run: sudo apt-get update; sudo apt-get install --no-install-recommends libudev-dev - - - name: Use Rust Cache - if: ${{ runner.os == 'Linux' }} - uses: Swatinem/rust-cache@v2.0.1 - - - name: Run build --release - run: cargo build --release - - - name: Release Linux - uses: softprops/action-gh-release@v1 - if: ${{ runner.os == 'Linux' }} - with: - files: | - target/release/game - assets - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Release Windows - uses: softprops/action-gh-release@v1 - if: ${{ runner.os == 'Windows' }} - with: - files: | - target/release/game.exe - assets - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + runs-on: ${{ matrix.os }} + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Get Rust toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: ${{ matrix.toolchain }} + override: true + + - name: Install alsa + if: ${{ runner.os == 'Linux' }} + run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev + + - name: Install udev + if: ${{ runner.os == 'Linux' }} + run: sudo apt-get update; sudo apt-get install --no-install-recommends libudev-dev + + - name: Use Rust Cache + if: ${{ runner.os == 'Linux' }} + uses: Swatinem/rust-cache@v2.0.1 + + - name: Run build --release + run: cargo build --release + + - name: Release Linux + uses: softprops/action-gh-release@v1 + if: ${{ runner.os == 'Linux' }} + with: + files: | + target/release/game + assets + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Release Windows + uses: softprops/action-gh-release@v1 + if: ${{ runner.os == 'Windows' }} + with: + files: | + target/release/game.exe + assets + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file