mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-29 23:28:45 +00:00
Summary:
- Add the bundled Policy plugin with policy-backed doctor checks for channel conformance.
- Add `openclaw policy check` attestations, accepted-attestation drift checks, and opt-in doctor repair.
- Add policy CLI docs, generated plugin inventory/reference docs, and changelog credit.
Verification:
- node --import tsx scripts/sync-plugin-versions.ts --check
- pnpm plugins:inventory:check
- pnpm docs:list
- git diff --check origin/main..HEAD
- node scripts/run-vitest.mjs extensions/policy/src/policy-state.test.ts extensions/policy/src/cli.test.ts extensions/policy/src/doctor/register.test.ts src/flows/bundled-health-checks.test.ts src/cli/program/register.maintenance.test.ts
- codex review --uncommitted; accepted finding fixed, reran clean
- codex review --commit HEAD
- GitHub CI for 4e09b067f4: CI, Workflow Sanity, CodeQL, CodeQL Critical Quality, OpenGrep PR Diff, Real behavior proof, Dependency Change Awareness all green; reran failed Windows Node setup job successfully
Co-authored-by: Gio Della-Libera <giodl73@gmail.com>
Co-authored-by: Gio Della-Libera <giodl@microsoft.com>
27 lines
720 B
TypeScript
27 lines
720 B
TypeScript
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
|
|
import { registerPolicyCli } from "./src/cli.js";
|
|
import { registerPolicyDoctorChecks } from "./src/doctor/register.js";
|
|
|
|
export default definePluginEntry({
|
|
id: "policy",
|
|
name: "Policy",
|
|
description: "Adds policy-backed doctor checks for workspace conformance.",
|
|
register(api) {
|
|
api.registerCli(
|
|
async ({ program }) => {
|
|
registerPolicyCli(program);
|
|
},
|
|
{
|
|
descriptors: [
|
|
{
|
|
name: "policy",
|
|
description: "Check policy requirements and emit audit evidence",
|
|
hasSubcommands: true,
|
|
},
|
|
],
|
|
},
|
|
);
|
|
registerPolicyDoctorChecks();
|
|
},
|
|
});
|