Pull Request for 204/merge by federicoweber #844
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: Pull Request | |
run-name: Pull Request for ${{ github.ref_name }} by ${{ github.actor }} | |
concurrency: | |
group: ${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
permissions: write-all | |
on: | |
pull_request: {} | |
workflow_dispatch: {} | |
push: | |
branches: | |
- main | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build_release_macos: | |
strategy: | |
matrix: | |
target: [x86_64-apple-darwin, aarch64-apple-darwin] | |
name: Build CLI for ${{ matrix.target }} | |
runs-on: macos-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: "true" | |
- name: Setup Rust & Cargo | |
uses: ./.github/actions/setup_rust_cargo | |
if: "!cancelled()" | |
- name: Run tests | |
uses: ./.github/actions/run_tests | |
if: "!cancelled()" | |
with: | |
target: ${{ matrix.target }} | |
- name: Build ${{ matrix.target }} target | |
uses: ./.github/actions/build_cli_macos_target | |
if: "!cancelled()" | |
with: | |
target: ${{ matrix.target }} | |
profile: release | |
- name: Upload results using action from ${{ matrix.target }} | |
uses: ./.github/actions/upload_test_results | |
if: "!cancelled()" | |
with: | |
workspace: ${{ github.workspace }} | |
target: ${{ matrix.target }} | |
trunk-staging-token: ${{ secrets.TRUNK_STAGING_ORG_API_TOKEN }} | |
build_release_linux: | |
strategy: | |
matrix: | |
include: | |
- target: x86_64-unknown-linux-musl | |
runs-on: public-amd64-2xlarge | |
- target: aarch64-unknown-linux-musl | |
runs-on: public-arm64-2xlarge | |
name: Build CLI for ${{ matrix.target }} | |
runs-on: ${{ matrix.runs-on }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: "true" | |
- name: Setup Rust & Cargo | |
uses: ./.github/actions/setup_rust_cargo | |
if: "!cancelled()" | |
- name: Run tests | |
uses: ./.github/actions/run_tests | |
if: "!cancelled()" | |
with: | |
target: ${{ matrix.target }} | |
- name: Build ${{ matrix.target }} target | |
uses: ./.github/actions/build_cli_linux_target | |
if: "!cancelled()" | |
with: | |
target: ${{ matrix.target }} | |
profile: release | |
- name: Upload results using action from ${{ matrix.target }} | |
uses: ./.github/actions/upload_test_results | |
if: "!cancelled()" | |
with: | |
workspace: ${{ github.workspace }} | |
target: ${{ matrix.target }} | |
trunk-staging-token: ${{ secrets.TRUNK_STAGING_ORG_API_TOKEN }} | |
trunk_check_runner: | |
name: Trunk Check runner [linux] | |
runs-on: public-amd64-2xlarge | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Rust & Cargo | |
uses: ./.github/actions/setup_rust_cargo | |
- name: Setup Ruby | |
uses: ./.github/actions/setup_ruby | |
- name: Build workspace | |
run: cargo build --all | |
- name: Setup and build pyo3 | |
uses: ./.github/actions/setup_build_pyo3 | |
- name: Setup and build wasm | |
uses: ./.github/actions/setup_build_wasm | |
- name: Trunk Check | |
uses: trunk-io/trunk-action@v1 | |
with: | |
cache: false |