Merge pull request #255 from PeggyJV/collin/gov-multicall #46
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
on: | |
push: | |
# Sequence of patterns matched against refs/tags | |
tags: | |
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10 | |
name: Automated Release | |
permissions: | |
contents: write | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
release: | |
name: build-release-assets | |
runs-on: ubuntu-20.04 | |
steps: | |
# Setup Rust Environment | |
- name: setup-rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: stable | |
# Checkout repository code | |
- name: checkout-code | |
uses: actions/checkout@v2 | |
- name: "Check version" | |
run: scripts/check_version.sh | |
# Rust Cache | |
- name: rust-cache | |
uses: actions/cache@v3 | |
id: rust-cache | |
with: | |
path: | | |
~/.cargo/bin | |
~/.cargo/registry/index | |
~/.cargo/registry/cache | |
~/.cargo/git/db | |
target | |
key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }} | |
# Install OpenSSL dependencies | |
- name: install-packages | |
run: sudo apt-get install -y libssl-dev musl-tools | |
# Build Rust Artifacts | |
- name: build-rust | |
run: | | |
rustup target add x86_64-unknown-linux-musl | |
cargo build --target x86_64-unknown-linux-musl --release --all | |
# Create Release and Upload artifacts | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: | | |
target/x86_64-unknown-linux-musl/release/steward | |
LICENSE | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |