Skip to content

Commit 4f576ec

Browse files
committed
LLM CI/CD fix
1 parent 57c119f commit 4f576ec

File tree

2 files changed

+19
-4
lines changed

2 files changed

+19
-4
lines changed

.github/workflows/llm-instructions-lint.yml

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,27 @@ jobs:
2626
- name: Checkout
2727
uses: actions/checkout@v6.0.1
2828

29-
- name: Setup Node.js
30-
uses: actions/setup-node@v4.4.0
29+
- name: Setup Node.js (cached)
30+
if: ${{ hashFiles('package-lock.json') != '' }}
31+
uses: actions/setup-node@v6.1.0
3132
with:
32-
node-version: "20"
33+
node-version: "22"
3334
cache: "npm"
35+
cache-dependency-path: package-lock.json
36+
37+
- name: Setup Node.js (no cache)
38+
if: ${{ hashFiles('package-lock.json') == '' }}
39+
uses: actions/setup-node@v6.1.0
40+
with:
41+
node-version: "22"
3442

3543
- name: Install dependencies
36-
run: npm ci
44+
run: |
45+
if [ -f package-lock.json ]; then
46+
npm ci
47+
else
48+
npm i --no-audit --no-fund
49+
fi
3750
3851
- name: Lint LLM instructions
3952
shell: pwsh

.llm/context.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,8 @@ pwsh -NoProfile -File scripts/lint-tests.ps1 # Lint test lifecycle
234234
pwsh -NoProfile -File scripts/lint-skill-sizes.ps1 # Skill file sizes
235235
```
236236

237+
LLM instructions lint workflow runs `npm run lint:llm` on Node 22. It enables npm cache only when `package-lock.json` is present; otherwise it installs with `npm i --no-audit --no-fund` to avoid lockfile errors.
238+
237239
Tests require Unity 2021.3+. Ask user to run tests and provide output.
238240

239241
---

0 commit comments

Comments
 (0)