mirror of
https://github.com/Heretek-AI/opencode-rea.git
synced 2026-11-07 10:56:10 -10:00
Merge branch 'main' into integration/v0.1
This commit is contained in:
6 files changed
+55
-9
No files matched your search
@@ -0,0 +1,38 @@
|
||||
name: Publish to npm (trusted publishing)
|
||||
|
||||
# OIDC trusted publishing: no long-lived npm token. Configure once at
|
||||
# https://www.npmjs.com/package/@heretek-ai/opencode-rea/access
|
||||
# (Trusted Publisher -> GitHub Actions -> Heretek-AI/opencode-rea,
|
||||
# workflow publish.yml), then every published GitHub release ships to npm
|
||||
# with provenance automatically.
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
id-token: write
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
name: Publish via OIDC
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: oven-sh/setup-bun@v2
|
||||
with:
|
||||
bun-version: latest
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 24
|
||||
registry-url: https://registry.npmjs.org
|
||||
- name: Install dependencies
|
||||
run: bun install
|
||||
- name: Typecheck
|
||||
run: bun run check
|
||||
- name: Run unit tests
|
||||
run: bun test --path-ignore-patterns 'review/**' test/unit
|
||||
- name: Build plugin
|
||||
run: bun run build
|
||||
- name: Publish to npm
|
||||
run: npm publish --provenance --access public
|
||||
@@ -33,7 +33,7 @@
|
||||
- User docs live in `README.md` (repo root): prerequisites (`rea setup
|
||||
--client opencode` first; plugin reuses that registration, never registers or
|
||||
edits an MCP server, never calls `ctx.mcp.transform`), install
|
||||
(`opencode plugin add <package or git spec>`, package `opencode-rea`),
|
||||
(`opencode plugin add <package or git spec>`, package `@heretek-ai/opencode-rea`),
|
||||
options (`server` default `"rea"`, `runtime` `"ask"|"allow"|"deny"` default
|
||||
`"ask"`, optional `codemode` boolean; see `src/options.ts`), agents/skills/commands/readiness
|
||||
(sources of truth: `src/agents.ts` + `agents/*.md`, `src/skills.ts` + `skills/*/SKILL.md`,
|
||||
|
||||
@@ -4,8 +4,8 @@ OpenCode v2 plugin that wires [REA](https://github.com/morluto/rea) reverse-engi
|
||||
agents, skills, slash commands, Code Mode catalog pinning, and a readiness tool
|
||||
into OpenCode — on top of an already-registered REA MCP server.
|
||||
|
||||
- Package: `opencode-rea`
|
||||
- Version: `0.1.0`
|
||||
- Package: `@heretek-ai/opencode-rea`
|
||||
- Version: `0.1.2`
|
||||
- Entry: `./dist/index.js` (`exports: { ".": "./dist/index.js" }`)
|
||||
- Shipped files: `dist`, `skills`, `agents`, `index.js`
|
||||
(`index.js` at the repo root re-exports `./dist/index.js`: the host resolves a
|
||||
@@ -38,7 +38,7 @@ If tools are missing later, the readiness tool points you back at doctor/setup
|
||||
## Install
|
||||
|
||||
```sh
|
||||
opencode plugin add opencode-rea
|
||||
opencode plugin add @heretek-ai/opencode-rea
|
||||
# or a git spec, e.g.
|
||||
# opencode plugin add [email protected]:<org>/opencode-rea.git
|
||||
```
|
||||
|
||||
+9
-1
@@ -1,10 +1,17 @@
|
||||
{
|
||||
"$schema": "https://json.schemastore.org/package.json",
|
||||
"name": "opencode-rea",
|
||||
"version": "0.1.0",
|
||||
"version": "0.1.2",
|
||||
"description": "OpenCode v2 plugin for REA (reverse-engineer-anything) MCP integration",
|
||||
"type": "module",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/Heretek-AI/opencode-rea.git"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
},
|
||||
"exports": {
|
||||
".": "./dist/index.js"
|
||||
},
|
||||
@@ -17,6 +24,7 @@
|
||||
"scripts": {
|
||||
"check": "tsc --noEmit -p tsconfig.json",
|
||||
"build": "tsc -p tsconfig.build.json",
|
||||
"prepublishOnly": "tsc -p tsconfig.build.json",
|
||||
"test": "bun test --path-ignore-patterns 'review/**' test/unit",
|
||||
"test:unit": "bun test --path-ignore-patterns 'review/**' test/unit",
|
||||
"test:integration": "bun test --path-ignore-patterns 'review/**' test/integration",
|
||||
|
||||
@@ -18,8 +18,8 @@ describe("T15 docs guard (README accuracy)", () => {
|
||||
devDependencies?: Record<string, string>
|
||||
}
|
||||
// Hard-assert known release values (fail loudly on drift).
|
||||
expect(pkg.name).toBe("opencode-rea")
|
||||
expect(pkg.version).toBe("0.1.0")
|
||||
expect(pkg.name).toBe("@heretek-ai/opencode-rea")
|
||||
expect(pkg.version).toBe("0.1.1")
|
||||
expect(pkg.exports).toEqual({ ".": "./dist/index.js" })
|
||||
expect(pkg.devDependencies?.["rea-agents"]).toBe("6.5.0")
|
||||
for (const entry of ["dist", "skills", "agents", "index.js"]) {
|
||||
@@ -29,7 +29,7 @@ describe("T15 docs guard (README accuracy)", () => {
|
||||
const readme = await Bun.file("README.md").text()
|
||||
// README must mention the same identity (not invented values).
|
||||
expect(readme).toContain("opencode-rea")
|
||||
expect(readme).toContain("0.1.0")
|
||||
expect(readme).toContain("0.1.2")
|
||||
expect(readme).toContain("6.5.0")
|
||||
expect(readme).toContain("./dist/index.js")
|
||||
for (const entry of ["dist", "skills", "agents", "index.js"]) {
|
||||
|
||||
@@ -3,7 +3,7 @@ import { describe, expect, test } from "bun:test"
|
||||
describe("T01 package scaffold", () => {
|
||||
test("package.json fields", async () => {
|
||||
const pkg = await Bun.file("package.json").json()
|
||||
expect(pkg.name).toBe("opencode-rea")
|
||||
expect(pkg.name).toBe("@heretek-ai/opencode-rea")
|
||||
expect(pkg.type).toBe("module")
|
||||
expect(pkg.exports).toEqual({ ".": "./dist/index.js" })
|
||||
expect(pkg.files).toEqual(expect.arrayContaining(["dist", "skills", "agents", "index.js"]))
|
||||
|
||||
Reference in new issue
Block a user