# SPDX-License-Identifier: AGPL-3.0-or-later name: CI helper description: Restore or build the shared Rust CI helper inputs: save: description: Save a missing helper cache on main required: false default: 'false' runs: using: composite steps: - name: Restore ci helper id: cache uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 with: path: target/debug/fluxer-ci key: >- fluxer-ci-bin-${{ runner.os }}-1.98.1-${{ hashFiles('Cargo.lock', 'Cargo.toml', 'tools/ci/Cargo.toml', 'tools/ci/src/**') }} - name: Build ci helper if: steps.cache.outputs.cache-hit != 'true' shell: bash run: cargo build --locked --package fluxer-ci - name: Save ci helper if: inputs.save == 'true' && github.ref == 'refs/heads/main' && steps.cache.outputs.cache-hit != 'true' uses: actions/cache/save@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 with: path: target/debug/fluxer-ci key: ${{ steps.cache.outputs.cache-primary-key }}