diff --git a/.github/workflows/dev.yml b/.github/workflows/dev.yml index 3c030a7..6b88929 100644 --- a/.github/workflows/dev.yml +++ b/.github/workflows/dev.yml @@ -1,11 +1,14 @@ -on: push +on: + push: + branches: + - "*" env: CARGO_TERM_COLOR: always name: Development Build jobs: - release: + build: name: ${{ matrix.target }} strategy: fail-fast: false @@ -44,6 +47,6 @@ jobs: - name: Upload Build Artifacts uses: actions/upload-artifact@master with: - name: ${{ matrix.target }} + name: bmap-server-${{ matrix.target }} path: | - target/release/bmap-server + target/release/bmap-server* diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index cbb3771..52d159b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -7,13 +7,28 @@ env: CARGO_TERM_COLOR: always jobs: - release: - name: Release Build - ${{ matrix.platform }} + build: + name: Build ${{ matrix.target }} strategy: - fail-fast: false + fail-fast: true matrix: - platform: [ubuntu-latest] - runs-on: ${{ matrix.platform }} + include: + - name: linux-amd64 + runner: ubuntu-latest + target: x86_64-unknown-linux-gnu + - name: linux-i686 + runner: ubuntu-latest + target: i686-unknown-linux-gnu + - name: linux-arm64 + runner: ubuntu-latest + target: aarch64-unknown-linux-gnu + - name: macos-amd64 + runner: macos-latest + target: x86_64-apple-darwin + - name: macos-arm64 + runner: macos-latest + target: aarch64-apple-darwin + runs-on: ${{ matrix.runner }} steps: - uses: actions/checkout@master - name: Setup Rust Toolchain @@ -28,8 +43,22 @@ jobs: command: build args: --release + - name: Upload Build Artifacts + uses: actions/upload-artifact@master + with: + name: bmap-server-${{ matrix.target }} + path: | + target/release/bmap-server* + + release: + name: Create release + needs: build + runs-on: "ubuntu-latest" + steps: + - name: Download Build Artifacts + uses: actions/download-artifact@master - name: Create a Release uses: softprops/action-gh-release@v2 with: files: | - target/release/bmap-server + bmap-server*