ctc-oss / fapolicy-analyzer

Tools to assist with the configuration and management of fapolicyd.
https://ctc-oss.github.io/fapolicy-analyzer
GNU General Public License v3.0
13 stars 5 forks source link

Add semver check for crates #704

Closed jw3 closed 11 months ago

jw3 commented 1 year ago

A common error (that goes undetected) when pushing new code to crates is to forget to bump the crate version. We need an automated check to fail the build if a version bump is missing.

See https://github.com/obi1kenobi/cargo-semver-checks

There is an action https://github.com/obi1kenobi/cargo-semver-checks-action

jw3 commented 1 year ago

cargo semver-checks check-release --workspace --baseline-rev HEAD

Index checks against HEAD

workflow example

  semver-check:
    if: github.ref != 'refs/heads/master'
    needs: [fmt]
    runs-on: ubuntu-20.04
    steps:
      - uses: actions/checkout@v3
      - uses: actions/setup-python@v4
      - uses: dtolnay/rust-toolchain@stable
      - uses: taiki-e/install-action@v2
        with:
          tool: cargo-semver-checks
      - run: cargo semver-checks check-release