-
Notifications
You must be signed in to change notification settings - Fork 5
99 lines (81 loc) · 2.85 KB
/
Copy pathaudit.yml
File metadata and controls
99 lines (81 loc) · 2.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: Audit
on:
push:
branches: [ master ]
pull_request:
schedule:
- cron: '0 12 * * *' # Daily, 12:00:00 UTC
workflow_dispatch:
permissions: {}
env:
CARGO_TERM_COLOR: always
jobs:
cargo-audit:
name: Cargo Audit - ${{ matrix.name }}
runs-on: ubuntu-latest
permissions:
contents: read
checks: write
issues: write
strategy:
fail-fast: false
matrix:
include:
- name: Fresh Lockfile
lockfile: Cargo.lock
- name: Recent Lockfile
lockfile: Cargo-recent.lock
- name: Minimal Lockfile
lockfile: Cargo-minimal.lock
steps:
- name: Checkout Repository
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
persist-credentials: false
- name: Setup Rust Cache
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
- name: Setup cargo-rbmt
uses: ./.github/actions/setup-rbmt
- name: Install cargo-rbmt Tools
shell: bash
run: cargo rbmt tools
- name: Generate Fresh Lockfile
if: ${{ matrix.lockfile == 'Cargo.lock' }}
shell: bash
run: cargo generate-lockfile
- name: Select Lockfile
if: ${{ matrix.lockfile != 'Cargo.lock' }}
shell: bash
run: cp ${{ matrix.lockfile }} Cargo.lock
- uses: rustsec/audit-check@69366f33c96575abad1ee0dba8212993eecbe998 # v2.0.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
shellcheck:
name: ShellCheck
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
persist-credentials: false
- name: Run ShellCheck
shell: bash
run: find . -name '*.sh' -print -exec shellcheck {} +
zizmor:
name: Zizmor
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
persist-credentials: false
- name: Setup Rust Cache
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
- name: Setup cargo-rbmt
uses: ./.github/actions/setup-rbmt
- name: Install cargo-rbmt Tools
shell: bash
run: cargo rbmt tools
- name: Run Zizmor
shell: bash
run: zizmor .