zlicenser-server 0.1.2

Server library for the zlicenser hardware-bound software licensing framework.
Documentation
name: CI

on:
  push:
    branches: [main]
  pull_request:

env:
  CARGO_TERM_COLOR: always
  RUST_BACKTRACE: 1

jobs:
  test:
    name: Test
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
        with:
          path: zlicenser-server
      - uses: actions/checkout@v4
        with:
          repository: zal-analytics/zlicenser-protocol
          path: zlicenser-protocol
      - uses: dtolnay/rust-toolchain@stable
      - uses: Swatinem/rust-cache@v2
        with:
          workspaces: "zlicenser-server -> target"
      - run: cargo test -p zlicenser-server
        working-directory: zlicenser-server
      - run: cargo test -p zlicenser-server --all-features
        working-directory: zlicenser-server
      - run: cargo test -p zlicenser-server --no-default-features
        working-directory: zlicenser-server

  clippy:
    name: Clippy
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
        with:
          path: zlicenser-server
      - uses: actions/checkout@v4
        with:
          repository: zal-analytics/zlicenser-protocol
          path: zlicenser-protocol
      - uses: dtolnay/rust-toolchain@stable
        with:
          components: clippy
      - uses: Swatinem/rust-cache@v2
        with:
          workspaces: "zlicenser-server -> target"
      - run: cargo clippy --workspace --all-features -- -D warnings
        working-directory: zlicenser-server
      - run: cargo clippy -p zlicenser-server --no-default-features -- -D warnings
        working-directory: zlicenser-server

  fmt:
    name: Rustfmt
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: dtolnay/rust-toolchain@stable
        with:
          components: rustfmt
      - run: cargo fmt --check

  deny:
    name: Deny
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
        with:
          path: zlicenser-server
      - uses: actions/checkout@v4
        with:
          repository: zal-analytics/zlicenser-protocol
          path: zlicenser-protocol
      - uses: EmbarkStudios/cargo-deny-action@v2
        with:
          manifest-path: zlicenser-server/Cargo.toml

  audit:
    name: Audit
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: rustsec/audit-check@v2
        with:
          token: ${{ secrets.GITHUB_TOKEN }}