d107127017
Adds .github/workflows/** to both path filters. A broken step, a moved script path or a wrong runner label now fails on the commit that caused it, instead of surfacing later against an unrelated source change and looking like that change's fault. This session produced exactly that bug: after the branding tools moved under tools/, the workflow still ran `sh check-branding.sh` at the old path, and it was caught by reading the file rather than by CI. The limit is worth stating: this validates the job body, not the trigger block. Break `on:` and the symptom is silence, which is indistinguishable from success. Workflow edits are rare enough that the extra builds cost nothing, and CI config is the definition of how the project is built and verified — it belongs on the source side of "source code edits only", not with the docs. kolmekivi additionally gains the pull_request path filter the other two already had. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WHt4DykxXaQnyaJfyS8KCn
72 lines
2.3 KiB
YAML
72 lines
2.3 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
paths:
|
|
- 'src/**'
|
|
- 'xtask/**'
|
|
- 'Cargo.toml'
|
|
- 'Cargo.lock'
|
|
- 'bundler.toml'
|
|
- 'tools/**'
|
|
# This workflow validates itself: a broken step, a moved script path or a
|
|
# wrong runner label then fails loudly on the commit that caused it, rather
|
|
# than surfacing later against an unrelated source change. Note the limit -
|
|
# it checks the job body, not the trigger block above. Break `on:` and the
|
|
# symptom is silence, which looks like success.
|
|
- '.github/workflows/**'
|
|
# Mirrors the push filter. Without it a PR touching only the README would run a
|
|
# full build - the branch filter alone constrains where, not what.
|
|
pull_request:
|
|
branches: [ master ]
|
|
paths:
|
|
- 'src/**'
|
|
- 'xtask/**'
|
|
- 'Cargo.toml'
|
|
- 'Cargo.lock'
|
|
- 'bundler.toml'
|
|
- 'tools/**'
|
|
- '.github/workflows/**'
|
|
workflow_dispatch:
|
|
|
|
# Target the self-hosted Rust/audio runner registered to the `musiikki` org.
|
|
#
|
|
# The runner is host-mode, so the rustup toolchain installed for the
|
|
# `gitea-runner` user is used directly — nothing installs per run, and the cargo
|
|
# registry cache stays warm between jobs.
|
|
#
|
|
# Adapted from musiikki/nih-plug-template. The template gates VST3 behind an
|
|
# opt-in `vst3` feature and so builds twice; this plugin always ships VST3
|
|
# (nih_plug is taken with default features), so one build covers both formats.
|
|
|
|
jobs:
|
|
build:
|
|
name: Build
|
|
runs-on: rust-audio
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Toolchain
|
|
run: |
|
|
cargo --version
|
|
rustc --version
|
|
echo "CARGO_HOME=${CARGO_HOME:?not set on this runner}"
|
|
|
|
# Cheap and needs no toolchain, so it runs first: a rename that only
|
|
# landed in half the files is worth catching before spending a build on it.
|
|
- name: Branding consistency
|
|
run: sh tools/check-branding.sh
|
|
|
|
- name: Build
|
|
run: cargo build --release
|
|
|
|
- name: Test
|
|
run: cargo test --release
|
|
|
|
# Proves the xtask bundler still works, which a plain `cargo build` does
|
|
# not exercise — the bundle step is where bundler.toml and the crate name
|
|
# have to agree.
|
|
- name: Bundle
|
|
run: cargo xtask bundle bari_206 --release
|