Skip to content

Commit 28ece17

Browse files
authored
ci: add cargo-deny workflow (#38)
* ci: add cargo-deny workflow Adds a GitHub Actions workflow that runs cargo-deny check on every pull request and push to main. Uses the existing deny.toml added in v0.8.0 so CI now enforces the advisory/license/source policy. Actions pinned by commit SHA: - actions/checkout@de0fac2e (v6.0.2) - EmbarkStudios/cargo-deny-action@91bf2b62 (v2.0.17) Closes the follow-up noted in deny.toml ("CI integration is a follow-up; this file establishes the policy"). * fix(ci): add minimal contents:read permissions to deny.yml CodeQL + Cursor flagged missing permissions block. cargo-deny only reads the repo; explicit contents:read matches ci.yml and release.yml.
1 parent ef5b071 commit 28ece17

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

.github/workflows/deny.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: cargo-deny
2+
3+
on:
4+
pull_request:
5+
push:
6+
branches: [main]
7+
8+
# Minimal permissions — cargo-deny only needs to read the repo.
9+
# Matches the pattern used by ci.yml and release.yml. Hardening per
10+
# CodeQL + cursor review on #38.
11+
permissions:
12+
contents: read
13+
14+
jobs:
15+
cargo-deny:
16+
name: cargo-deny check
17+
runs-on: ubuntu-latest
18+
steps:
19+
# actions/checkout@v6.0.2
20+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
21+
# EmbarkStudios/cargo-deny-action@v2.0.17
22+
- uses: EmbarkStudios/cargo-deny-action@91bf2b620e09e18d6eb78b92e7861937469acedb
23+
with:
24+
log-level: warn
25+
command: check
26+
arguments: --all-features

0 commit comments

Comments
 (0)