Skip to content

ci: don't dev build on tag push & build on release beforehand #2

ci: don't dev build on tag push & build on release beforehand

ci: don't dev build on tag push & build on release beforehand #2

Workflow file for this run

on:
push:
tags:
- "*"
env:
CARGO_TERM_COLOR: always
jobs:
build:
name: Build ${{ matrix.target }}
strategy:
fail-fast: true
matrix:
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
uses: dtolnay/rust-toolchain@nightly
- name: Rust Dependency Cache
uses: Swatinem/rust-cache@master
- name: Build
uses: clechasseur/rs-cargo@v2
with:
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: |
bmap-server*