-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (46 loc) · 1.71 KB
/
ci.yml
File metadata and controls
57 lines (46 loc) · 1.71 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
name: CI
# Adapted from openai/codex-plugin-cc's pull-request-ci.yml.
# Modified by JohnnyVicious (2026): wraps OpenCode (not Codex), so installs
# `opencode-ai` instead of `@openai/codex` for the integration tests, and
# runs only on a single Node version matching the package.json
# `engines.node` floor. (Apache License 2.0 §4(b) modification notice —
# see NOTICE.)
on:
pull_request:
push:
branches:
- main
permissions:
contents: read
jobs:
test:
name: Test
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Check out repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Set up Node.js
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version: 22
cache: npm
- name: Install dependencies
run: npm ci
- name: Install OpenCode CLI
run: npm install -g opencode-ai
- name: Check version metadata is in sync
run: npm run check-version
- name: Syntax-check companion scripts
run: |
node --check plugins/opencode/scripts/opencode-companion.mjs
node --check plugins/opencode/scripts/stop-review-gate-hook.mjs
node --check plugins/opencode/scripts/lib/git.mjs
node --check plugins/opencode/scripts/lib/prompts.mjs
node --check plugins/opencode/scripts/lib/process.mjs
node --check plugins/opencode/scripts/lib/opencode-server.mjs
node --check plugins/opencode/scripts/lib/review-agent.mjs
node --check plugins/opencode/scripts/lib/model.mjs
node --check scripts/bump-version.mjs
- name: Run tests
run: npm test