permitit 0.1.0

Cute little library to permit a specific error
Documentation
name: Test
description: |
  Run nextest, doc tests, and audit on pushes or PRs.

on:
  push:
    tags:
      - 'v*.*.*'
    branches:
      - '**'
  pull_request:

jobs:
  test:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout repository
        uses: actions/checkout@v4

      # TODO: Switch to something maintained ideally
      # Maybe https://github.com/marketplace/actions/setup-rust-toolchain-for-github-ci
      - name: Install rust
        uses: actions-rs/toolchain@v1
        with:
          toolchain: stable
          profile: minimal
          override: true
          components: clippy

      # https://github.com/actions/cache/blob/main/examples.md#rust---cargo
      - name: Cache cargo
        uses: actions/cache@v4
        with:
          path: |
            ~/.cargo/bin/
            ~/.cargo/registry
            ~/.cargo/git
            target
          key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
          restore-keys: |
            ${{ runner.os }}-cargo-registry-

      - name: Install cargo-nextest
        run: |
          if ! command -v cargo-nextest &> /dev/null; then
            cargo install cargo-nextest --locked
          fi

      - name: Install cargo-audit
        run: |
          if ! command -v cargo-audit &> /dev/null; then
            cargo install cargo-audit --locked
          fi

      - name: Run nextest
        run: cargo nextest run

      - name: Run doc tests
        run: cargo test --doc

      - name: Run audit
        run: cargo audit