Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 28 additions & 11 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,36 @@
version: 2

updates:
- package-ecosystem: "github-actions"
directory: "/"
- package-ecosystem: github-actions
directory: /
schedule:
interval: "weekly"
interval: weekly
cooldown:
default-days: 7
groups:
actions-deps:
patterns:
- '*'
actions:
patterns: ["*"]
commit-message:
prefix: ci
labels:
- dependencies
- github-actions
ignore:
- dependency-name: DeterminateSystems/*

- package-ecosystem: "npm"
directory: "/"
- package-ecosystem: npm
directory: /
schedule:
interval: "weekly"
interval: weekly
cooldown:
default-days: 7
semver-major-days: 14
semver-minor-days: 7
semver-patch-days: 3
groups:
npm-deps:
patterns:
- '*'
patterns: ["*"]
labels:
- dependencies
- npm

7 changes: 5 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,11 @@ jobs:
contents: read
id-token: write
steps:
- uses: actions/checkout@v6
- uses: DeterminateSystems/determinate-nix-action@v3
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false

- uses: DeterminateSystems/determinate-nix-action@main
- uses: DeterminateSystems/flakehub-cache-action@main
Comment on lines +21 to 22
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot May 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Identify action refs in workflows that are not pinned to 40-char commit SHAs.
rg -nP 'uses:\s*[^@]+@(?!(?:[0-9a-f]{40}\b))\S+' .github/workflows

Repository: DeterminateSystems/detsys-ts

Length of output: 456


Pin DeterminateSystems action refs to commit SHAs instead of @main.

Using @main is mutable and weakens supply-chain security guarantees. Pin to specific 40-character commit SHAs to ensure immutable workflow execution.

Suggested change
-      - uses: DeterminateSystems/determinate-nix-action@main
-      - uses: DeterminateSystems/flakehub-cache-action@main
+      - uses: DeterminateSystems/determinate-nix-action@<commit-sha>
+      - uses: DeterminateSystems/flakehub-cache-action@<commit-sha>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml around lines 21 - 22, Replace the mutable `@main`
refs for the DeterminateSystems actions with immutable 40-character commit SHAs:
update the two usages "DeterminateSystems/determinate-nix-action@main" and
"DeterminateSystems/flakehub-cache-action@main" to use their specific commit
SHAs (full 40-char values) so the workflow runs a pinned, immutable revision;
obtain the appropriate commit SHA for each action from their repository and
substitute it in place of "@main".

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My zizmor config explicitly says that this is okay

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lucperkins, you're right — I can see from the .github/zizmor.yml changes in this PR that DeterminateSystems/* is explicitly listed under policies with the ref-pin exception. That's a deliberate, documented policy decision. I'll disregard this in future reviews.

ʕ •ᴥ•ʔ


✏️ Learnings added
Learnt from: lucperkins
Repo: DeterminateSystems/detsys-ts PR: 182
File: .github/workflows/ci.yml:21-22
Timestamp: 2026-05-12T18:06:37.874Z
Learning: In the DeterminateSystems/detsys-ts repository, `DeterminateSystems/*` GitHub Actions (e.g., `DeterminateSystems/determinate-nix-actionmain`, `DeterminateSystems/flakehub-cache-actionmain`) are intentionally allowed to use mutable `main` refs rather than pinned commit SHAs. This exception is explicitly declared in `.github/zizmor.yml` under `policies` with `ref-pin` for the `DeterminateSystems/*` namespace, and `DeterminateSystems/*` is also excluded from Dependabot updates in `.github/dependabot.yml`. Do not flag these as unpinned action refs.

Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.


- name: Check Nix formatting
Expand Down
17 changes: 11 additions & 6 deletions .github/workflows/update-downstream.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,11 @@ jobs:
GH_TOKEN: ${{ secrets.detsys_pr_bot_token }} # for `gh pr create`
steps:
- name: Check out detsys-ts
uses: actions/checkout@v6
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
path: current
token: ${{ env.GH_TOKEN }}
persist-credentials: false

- name: Get last detsys-ts commit message
id: commit-msg
Expand All @@ -55,23 +56,27 @@ jobs:
echo "msg=${MSG}" >> $GITHUB_OUTPUT

- name: Check out ${{ env.TARGET_REPO }}
uses: actions/checkout@v6
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
path: target
repository: ${{ env.TARGET_REPO }}
token: ${{ env.GH_TOKEN }}
persist-credentials: false

- name: Install Nix
uses: DeterminateSystems/determinate-nix-action@v3
uses: DeterminateSystems/determinate-nix-action@main

- name: Set up FlakeHub Cache
uses: DeterminateSystems/flakehub-cache-action@main
Comment thread
lucperkins marked this conversation as resolved.

- name: Configure Git for ${{ env.GIT_USER }}
working-directory: target
env:
GIT_EMAIL: ${{ env.GIT_EMAIL }}
GIT_USER: ${{ env.GIT_USER }}
run: |
git config user.name "${{ env.GIT_USER }}"
git config user.email "${{ env.GIT_EMAIL }}"
git config user.name "$GIT_USER"
git config user.email "$GIT_EMAIL"

- name: Make sure the repo is forked
working-directory: target
Expand All @@ -97,7 +102,7 @@ jobs:
fi

- name: Create Pull Request
uses: peter-evans/create-pull-request@v8
uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1
env:
COMMIT_MSG: ${{ steps.commit-msg.outputs.msg }}
with:
Expand Down
5 changes: 5 additions & 0 deletions .github/zizmor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
rules:
unpinned-uses:
config:
policies:
DeterminateSystems/*: ref-pin
Comment thread
lucperkins marked this conversation as resolved.