-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
207 additions
and
98 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
### {{ github.job }} | ||
|
||
name: Common job setup | ||
|
||
run: | ||
setup: | ||
name: Setup dependencies | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
lfs: {{ inputs.lfs }} | ||
- uses: Swatinem/rust-cache@v2 | ||
with: | ||
shared-key: ${{ inputs.cache_key }} | ||
cache-all-crates: true | ||
cache-on-failure: true | ||
- uses: subosito/flutter-action@v1 | ||
- name: Run sccache-cache | ||
uses: mozilla-actions/[email protected] | ||
with: | ||
version: "v0.4.0" | ||
- name: Cache cargo binaries | ||
uses: actions/cache@v2 | ||
with: | ||
path: | | ||
~/.cargo/bin/ | ||
key: ${{ runner.os }}-cargo-bin | ||
- name: Install LLVM | ||
if: ${{ runner.os }} == 'Linux' | ||
run: brew install llvm | ||
- name: Install dependencies | ||
if: ${{ runner.os }} == 'Linux' | ||
run: | | ||
./scripts/install-ubuntu-apt-dependencies.sh | ||
- uses: taiki-e/install-action@v2 | ||
with: | ||
tool: cargo-tarpaulin,cargo-nextest | ||
|
||
inputs: | ||
lfs: | ||
description: 'Enable LFS clone' | ||
required: true | ||
default: false | ||
cache_key: | ||
description: 'A cache key for this step' | ||
required: true | ||
default: 'shared_cache' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
name: CI builds | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
SCCACHE_GHA_ENABLED: true | ||
RUSTC_WRAPPER: sccache | ||
|
||
jobs: | ||
build-rust: | ||
runs-on: ${{ matrix.os }} | ||
name: Build rust crates on ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: | ||
- macos-14 | ||
- ubuntu-20.04 | ||
steps: | ||
- uses: ../actions/common.yml | ||
with: | ||
lfs: false | ||
cache_key: ${{ matrix.os }}_build | ||
- name: Run build | ||
run: cargo build | ||
- name: Upload build outputs | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: build_target | ||
path: target | ||
retention-days: 0 | ||
|
||
test-rust: | ||
needs: | ||
- build-rust | ||
runs-on: ${{ matrix.os }} | ||
name: Test rust crates on ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: | ||
- macos-14 | ||
- ubuntu-20.04 | ||
steps: | ||
- uses: ../actions/common.yml | ||
with: | ||
lfs: true | ||
cache_key: ${{ matrix.os }}_test | ||
- name: Download build target | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: build_target | ||
- name: Run tests | ||
run: ./scripts/test.sh | ||
|
||
lint-rust: | ||
needs: | ||
- build-rust | ||
runs-on: ${{ matrix.os }} | ||
name: Test rust crates on ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: | ||
- macos-14 | ||
- ubuntu-20.04 | ||
steps: | ||
- uses: ../actions/common.yml | ||
with: | ||
lfs: true | ||
cache_key: ${{ matrix.os }}_lint | ||
- name: Download build target | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: build_target | ||
- name: Run clippy | ||
run: ./scripts/clippy.sh |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,6 @@ | ||
name: macOS | ||
name: Build macOS | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
on: {} | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
@@ -88,55 +84,55 @@ jobs: | |
matrix: | ||
os: [macos-14] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
lfs: true | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
lfs: true | ||
|
||
- uses: subosito/flutter-action@v1 | ||
- name: Run sccache-cache | ||
uses: mozilla-actions/[email protected] | ||
with: | ||
version: "v0.4.0" | ||
- uses: subosito/flutter-action@v1 | ||
- name: Run sccache-cache | ||
uses: mozilla-actions/[email protected] | ||
with: | ||
version: "v0.4.0" | ||
|
||
- uses: Swatinem/rust-cache@v2 | ||
with: | ||
shared-key: "rust-cache-macos2" | ||
cache-all-crates: true | ||
cache-on-failure: true | ||
- name: Cache cargo binaries | ||
uses: actions/cache@v2 | ||
with: | ||
path: | | ||
~/.cargo/bin/ | ||
key: ${{ runner.os }}-cargo-bin | ||
- name: Install LLVM | ||
run: brew install llvm | ||
- uses: Swatinem/rust-cache@v2 | ||
with: | ||
shared-key: "rust-cache-macos2" | ||
cache-all-crates: true | ||
cache-on-failure: true | ||
- name: Cache cargo binaries | ||
uses: actions/cache@v2 | ||
with: | ||
path: | | ||
~/.cargo/bin/ | ||
key: ${{ runner.os }}-cargo-bin | ||
- name: Install LLVM | ||
run: brew install llvm | ||
|
||
- name: Build release | ||
run: cargo build --release --verbose --workspace --exclude augmented-ui --exclude midir | ||
- name: Build release | ||
run: cargo build --release --verbose --workspace --exclude augmented-ui --exclude midir | ||
|
||
- name: Upload plugin-host binary | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-plugin-host | ||
path: ./target/release/plugin-host | ||
- name: Upload plugin-host-gui2 binary | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-plugin-host-gui2 | ||
path: ./target/release/plugin-host-gui2 | ||
- name: Upload tremolo-plugin dylib | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-libtas_v2-dylib | ||
path: ./target/release/libtas_v2.dylib | ||
- name: Validate license information | ||
run: | | ||
if ! [ -x "$(command -v cargo-about)" ]; then | ||
cargo install cargo-about | ||
fi | ||
cargo about generate about.hbs | ||
- name: Upload plugin-host binary | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-plugin-host | ||
path: ./target/release/plugin-host | ||
- name: Upload plugin-host-gui2 binary | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-plugin-host-gui2 | ||
path: ./target/release/plugin-host-gui2 | ||
- name: Upload tremolo-plugin dylib | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-libtas_v2-dylib | ||
path: ./target/release/libtas_v2.dylib | ||
- name: Validate license information | ||
run: | | ||
if ! [ -x "$(command -v cargo-about)" ]; then | ||
cargo install cargo-about | ||
fi | ||
cargo about generate about.hbs | ||
run-snapshot-tests: | ||
name: Run snapshot tests | ||
|
@@ -145,35 +141,35 @@ jobs: | |
matrix: | ||
os: [macos-14] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
lfs: true | ||
- name: Run sccache-cache | ||
uses: mozilla-actions/[email protected] | ||
with: | ||
version: "v0.4.0" | ||
- uses: subosito/flutter-action@v1 | ||
- uses: Swatinem/rust-cache@v2 | ||
with: | ||
shared-key: "rust-cache-macos2" | ||
cache-all-crates: true | ||
cache-on-failure: true | ||
- name: Install ARM/x86 toolchains | ||
run: | | ||
rustup target add aarch64-apple-darwin | ||
rustup target add x86_64-apple-darwin | ||
- name: Install LLVM | ||
run: brew install llvm | ||
- name: Run snapshot tests | ||
run: | | ||
./scripts/dev.sh test-snapshots | ||
- name: Upload snapshot test results | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-snapshot-tests | ||
path: ./test | ||
if: ${{ failure() }} | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
lfs: true | ||
- name: Run sccache-cache | ||
uses: mozilla-actions/[email protected] | ||
with: | ||
version: "v0.4.0" | ||
- uses: subosito/flutter-action@v1 | ||
- uses: Swatinem/rust-cache@v2 | ||
with: | ||
shared-key: "rust-cache-macos2" | ||
cache-all-crates: true | ||
cache-on-failure: true | ||
- name: Install ARM/x86 toolchains | ||
run: | | ||
rustup target add aarch64-apple-darwin | ||
rustup target add x86_64-apple-darwin | ||
- name: Install LLVM | ||
run: brew install llvm | ||
- name: Run snapshot tests | ||
run: | | ||
./scripts/dev.sh test-snapshots | ||
- name: Upload snapshot test results | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ runner.os }}-snapshot-tests | ||
path: ./test | ||
if: ${{ failure() }} | ||
|
||
build-sequencer: | ||
name: Build Continuous looper | ||
|
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