Skip to content

Commit fc355a1

Browse files
authored
Pin GitHub Actions and pre-commit hooks to immutable hashes (#138)
1 parent 18a904f commit fc355a1

4 files changed

Lines changed: 42 additions & 27 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,42 +17,42 @@ jobs:
1717
runs-on: ubuntu-latest
1818
steps:
1919
- name: Checkout
20-
uses: actions/checkout@v7
20+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2121
with:
2222
persist-credentials: false
2323

2424
- name: Setup Node.js
25-
uses: actions/setup-node@v7
25+
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
2626
with:
2727
node-version: 26
2828

2929
- name: Setup Bun
30-
uses: oven-sh/setup-bun@v2
30+
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0
3131
with:
3232
bun-version: latest
3333

3434
- name: Install dependencies
3535
run: bun install --frozen-lockfile
3636

3737
- name: Run prek
38-
uses: j178/prek-action@v3.0.0
38+
uses: j178/prek-action@4e14d07f9231acabce116ccfca13b13dd9755ece # v3.0.0
3939

4040
build:
4141
name: Build
4242
runs-on: ubuntu-latest
4343
steps:
4444
- name: Checkout
45-
uses: actions/checkout@v7
45+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
4646
with:
4747
persist-credentials: false
4848

4949
- name: Setup Node.js
50-
uses: actions/setup-node@v7
50+
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
5151
with:
5252
node-version: 26
5353

5454
- name: Setup Bun
55-
uses: oven-sh/setup-bun@v2
55+
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0
5656
with:
5757
bun-version: latest
5858

‎.github/workflows/deploy.yml‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,22 +22,22 @@ jobs:
2222
runs-on: ubuntu-latest
2323
steps:
2424
- name: Checkout
25-
uses: actions/checkout@v7
25+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2626
with:
2727
persist-credentials: false
2828

2929
- name: Setup Node.js
30-
uses: actions/setup-node@v7
30+
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
3131
with:
3232
node-version: 26
3333

3434
- name: Setup Bun
35-
uses: oven-sh/setup-bun@v2
35+
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0
3636
with:
3737
bun-version: latest
3838

3939
- name: Setup Pages
40-
uses: actions/configure-pages@v6
40+
uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
4141

4242
- name: Install dependencies
4343
run: bun install --frozen-lockfile
@@ -49,13 +49,13 @@ jobs:
4949
run: bunx astro check
5050

5151
- name: Spell check
52-
uses: crate-ci/typos@v1.49.0
52+
uses: crate-ci/typos@00f422f3b19c57bc6338715ebfe3316d38768461 # v1.50.3
5353

5454
- name: Build
5555
run: bun run build
5656

5757
- name: Upload artifact
58-
uses: actions/upload-pages-artifact@v5
58+
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
5959
with:
6060
path: ./dist
6161

@@ -72,4 +72,4 @@ jobs:
7272
steps:
7373
- name: Deploy to GitHub Pages
7474
id: deployment
75-
uses: actions/deploy-pages@v5
75+
uses: actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346 # v5.0.1

‎.github/zizmor.yml‎

Lines changed: 0 additions & 7 deletions
This file was deleted.

‎.pre-commit-config.yaml‎

Lines changed: 28 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,61 @@
1+
priorities:
2+
fix: 0
3+
fix-eol: 20
4+
fix-whitespace: 30
5+
check: 40
6+
17
repos:
28
- repo: https://github.com/pre-commit/pre-commit-hooks
3-
rev: v6.0.0
9+
rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # frozen: v6.0.0
410
hooks:
511
- id: check-added-large-files
612
args: [--maxkb=500]
13+
priority: check
714
- id: check-case-conflict
15+
priority: check
816
- id: check-merge-conflict
17+
priority: check
918
- id: check-json
19+
priority: check
1020
- id: check-yaml
21+
priority: check
1122
- id: end-of-file-fixer
23+
priority: fix-eol
1224
- id: trailing-whitespace
1325
args: [--markdown-linebreak-ext=md]
26+
priority: fix-whitespace
1427

1528
- repo: https://github.com/python-jsonschema/check-jsonschema
16-
rev: 0.37.0
29+
rev: 0494aa7fa1314e98913a41227d8f0a515b2c1049 # frozen: 0.38.2
1730
hooks:
1831
- id: check-dependabot
32+
priority: check
1933
- id: check-github-workflows
34+
priority: check
2035

2136
- repo: https://github.com/rhysd/actionlint
22-
rev: v1.7.11
37+
rev: 914e7df21a07ef503a81201c76d2b11c789d3fca # frozen: v1.7.12
2338
hooks:
2439
- id: actionlint
40+
priority: check
2541

2642
- repo: https://github.com/zizmorcore/zizmor-pre-commit
27-
rev: v1.23.1
43+
rev: fa412071e4f5d44d44f9e365f4676f9df92456a2 # frozen: v1.30.1
2844
hooks:
2945
- id: zizmor
46+
priority: check
3047

3148
- repo: https://github.com/crate-ci/typos
32-
rev: v1.44.0
49+
rev: 00f422f3b19c57bc6338715ebfe3316d38768461 # frozen: v1.50.3
3350
hooks:
3451
- id: typos
52+
priority: check
3553

3654
- repo: https://github.com/oxc-project/mirrors-oxlint
37-
rev: v1.55.0
55+
rev: 7ab19fc41bc7c63cb01d4322509971371c285e16 # frozen: v1.85.0
3856
hooks:
3957
- id: oxlint
58+
priority: check
4059

4160
- repo: local
4261
hooks:
@@ -46,8 +65,11 @@ repos:
4665
language: system
4766
pass_filenames: false
4867
files: ^src/.*\.(ts|tsx|astro)$
68+
priority: check
4969

5070
- repo: meta
5171
hooks:
5272
- id: check-hooks-apply
73+
priority: check
5374
- id: check-useless-excludes
75+
priority: check

0 commit comments

Comments
 (0)