Skip to content

Feature/four state forwarding bits #912

Feature/four state forwarding bits

Feature/four state forwarding bits #912

Workflow file for this run

name: Public API Check
on:
pull_request:
branches:
- master
concurrency:
# Cancels pending runs when a PR gets updated.
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
# The workflow may fail if we change the public API in a pull request.
# We allow fail on this action. But we should manually check if the changes are reasonable when we see a failed action.
# It would be good if the workflow returns a neutral status when we find API changes. But it is currently not
# possible with Github actions.
jobs:
check-public-api-changes:
runs-on: ubuntu-latest
steps:
- name: Checkout mmtk-core
uses: actions/checkout@v2
with:
# Full git history needed
fetch-depth: 0
# cargo-public-api can be built with the latest stable toolchain.
- name: Install stable Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
# make it the active toolchain
override: true
# cargo-public-api needs a nightly toolchain installed in order to work.
# It does not have to be the active toolchain.
- name: Install nightly Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
- run: cargo --version
- run: cargo +nightly --version
- name: Install cargo-public-api
run: cargo install cargo-public-api
- name: API Diff
run: cargo public-api diff origin/${GITHUB_BASE_REF}..${{ github.event.pull_request.head.sha }} --deny=all