Skip to content

Commit 95f1095

Browse files
committed
Add pinact and zizmor workflow checks
1 parent f26a23a commit 95f1095

4 files changed

Lines changed: 69 additions & 7 deletions

File tree

‎.github/workflows/pinact.yaml‎

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Pinact
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
branches: ["**"]
8+
paths:
9+
- ".github/workflows/**"
10+
- ".github/actions/**"
11+
12+
permissions: {}
13+
14+
jobs:
15+
pinact:
16+
# Only run on pull requests from the same repository
17+
if: github.event.pull_request.head.repo.full_name == github.repository
18+
runs-on: ubuntu-latest
19+
steps:
20+
- name: Checkout
21+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
22+
with:
23+
persist-credentials: false
24+
25+
- name: Pin actions
26+
uses: suzuki-shunsuke/pinact-action@cf51507d80d4d6522a07348e3d58790290eaf0b6 # v2.0.0
27+
with:
28+
skip_push: true
29+
verify: true
30+
min_age: 7

‎.github/workflows/python-release.yml‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,17 @@ jobs:
88
release:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v4
11+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1212
- name: Set up Python 3.12
13-
uses: actions/setup-python@v1
13+
uses: actions/setup-python@0f07f7f756721ebd886c2462646a35f78a8bc4de # v1.2.4
1414
with:
1515
python-version: 3.12
1616
- name: Install build requirements
1717
run: python -m pip install uv
1818
- name: Build package
1919
run: uv build
2020
- name: Publish package
21-
uses: pypa/gh-action-pypi-publish@release/v1
21+
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # release/v1
2222
with:
2323
user: __token__
2424
password: ${{ secrets.pypi_password }}

‎.github/workflows/python-test.yml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ jobs:
77
format:
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: actions/checkout@v4
10+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1111
- name: Set up Python 3.12
12-
uses: actions/setup-python@v1
12+
uses: actions/setup-python@0f07f7f756721ebd886c2462646a35f78a8bc4de # v1.2.4
1313
with:
1414
python-version: 3.12
1515
- name: Install dependencies
@@ -24,9 +24,9 @@ jobs:
2424
matrix:
2525
python-version: ["3.9", "3.10", "3.11", "3.12"]
2626
steps:
27-
- uses: actions/checkout@v4
27+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
2828
- name: Set up Python ${{ matrix.python-version }}
29-
uses: actions/setup-python@v1
29+
uses: actions/setup-python@0f07f7f756721ebd886c2462646a35f78a8bc4de # v1.2.4
3030
with:
3131
python-version: ${{ matrix.python-version }}
3232
- name: Install dependencies

‎.github/workflows/zizmor.yaml‎

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Zizmor
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
branches: ["**"]
8+
paths:
9+
- ".github/workflows/**"
10+
- ".github/actions/**"
11+
12+
permissions: {}
13+
14+
jobs:
15+
zizmor:
16+
name: Run zizmor
17+
runs-on: ubuntu-latest
18+
permissions:
19+
contents: read
20+
actions: read
21+
steps:
22+
- name: Checkout repository
23+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
24+
with:
25+
persist-credentials: false
26+
27+
- name: Run zizmor
28+
uses: zizmorcore/zizmor-action@71321a20a9ded102f6e9ce5718a2fcec2c4f70d8 # v0.5.2
29+
with:
30+
advanced-security: false
31+
annotations: true
32+
min-severity: high

0 commit comments

Comments
 (0)