fixed release workflow #12
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: Release | |
# Do this on every push | |
on: | |
push: | |
tags: | |
- "v*" | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build-linux-release: | |
name: Build release for Linux | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install Rust, stable minimal toolchain | |
uses: dtolnay/rust-toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Build | |
run: .github/workflows/build.sh | |
- name: Upload tarball | |
uses: actions/upload-artifact@v2 | |
with: | |
name: linux.tar.gz | |
path: "*.tar.gz" | |
if-no-files-found: error | |
build-macos-13-release: | |
name: Build release for MacOS x86_64 | |
runs-on: macos-13 | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install Rust, stable minimal toolchain | |
uses: dtolnay/rust-toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Build | |
run: .github/workflows/build.sh | |
- name: Upload tarball | |
uses: actions/upload-artifact@v4 | |
with: | |
name: macos13.tar.gz | |
path: "*.tar.gz" | |
if-no-files-found: error | |
build-macos-14-release: | |
name: Build release for MacOS arm64 | |
runs-on: macos-14 | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install Rust, stable minimal toolchain | |
uses: dtolnay/rust-toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Build | |
run: .github/workflows/build.sh | |
- name: Upload tarball | |
uses: actions/upload-artifact@v4 | |
with: | |
name: macos14.tar.gz | |
path: "*.tar.gz" | |
if-no-files-found: error | |
create-release: | |
name: Create a new release | |
runs-on: ubuntu-latest | |
needs: [build-linux-release, build-macos-13-release, build-macos-14-release] | |
steps: | |
- name: Download all artifacts | |
uses: actions/download-artifact@v4 | |
- name: Provide new release asset | |
uses: "marvinpinto/action-automatic-releases@latest" | |
with: | |
repo_token: "${{ secrets.GITHUB_TOKEN }}" | |
prerelease: false | |
files: | | |
*.tar.gz |