name: Security Audit

on:
  schedule:
    - cron: "0 0 * * 0"
  push:
    paths: ["Cargo.lock", "Cargo.toml"]
  pull_request:
    paths: ["Cargo.lock", "Cargo.toml"]

jobs:
  audit:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: Run cargo audit
        uses: actions-rs/audit-action@v1
        with:
          token: ${{ secrets.GITHUB_TOKEN }}
