feat(modrinth): allow filtering by loader as well as game version #17
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: Rust | |
on: | |
[push, pull_request] | |
env: | |
CARGO_TERM_COLOR: always | |
rust_target: x86_64-unknown-linux-musl | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install musl dependencies | |
if: ${{ env.rust_target == 'x86_64-unknown-linux-musl' }} | |
run: sudo apt-get update && sudo apt-get install musl-tools | |
- name: Install rust toolchain | |
id: init | |
run: | | |
rustup toolchain install stable --profile minimal | |
rustup target add "$rust_target" | |
echo "##[set-output name=sha7;]$(echo ${GITHUB_SHA:0:7})" | |
- uses: Swatinem/rust-cache@v2 | |
- name: Build | |
run: cargo build --verbose --release --target "$rust_target" | |
- name: Upload a Build Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: server-wrapper-${{ steps.init.outputs.sha7 }}-${{ env.rust_target }} | |
path: target/${{ env.rust_target }}/release/server-wrapper | |
retention-days: 90 |