Skip to content

feat: download prebuilt binary in the action #30

feat: download prebuilt binary in the action

feat: download prebuilt binary in the action #30

Workflow file for this run

name: Test action
on:
# Runs when someone pushes to the main branch.
push:
branches: [main]
# Runs when someone updates a PR.
pull_request:
# Allow running manually.
workflow_dispatch:
jobs:
test:
name: Test action
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
prebuilt: [true, false]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
- name: Initialize Rust project
run: cargo init --bin
- name: Cache build files
uses: Leafwing-Studios/cargo-cache@v2
- name: Build Rust project
run: cargo build
- name: cargo-sweep
uses: ./
with:
use-prebuilt: ${{ matrix.prebuilt }}
- name: Check Rust project
run: cargo check
# `cargo-sweep` should delete all build files, but keep the check ones.