@pome-sh/cli 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/build-info.json +3 -3
- package/dist/src/cli/agent-resolver.d.ts +3 -0
- package/dist/src/cli/agent-resolver.js +10 -0
- package/dist/src/cli/checks-add.d.ts +32 -0
- package/dist/src/cli/checks-add.js +236 -0
- package/dist/src/cli/checks.d.ts +21 -0
- package/dist/src/cli/checks.js +150 -0
- package/dist/src/cli/main.js +28 -0
- package/dist/src/runner/runTask.d.ts +10 -10
- package/dist/src/task/insertCriterion.d.ts +15 -0
- package/dist/src/task/insertCriterion.js +62 -0
- package/dist/src/task/parseTask.d.ts +5 -0
- package/dist/src/task/parseTask.js +11 -0
- package/dist/src/task/taskSchema.d.ts +4 -4
- package/node_modules/@pome-sh/sdk/dist/checks.d.ts +54 -0
- package/node_modules/@pome-sh/sdk/dist/checks.js +143 -0
- package/node_modules/@pome-sh/sdk/dist/checks.js.map +1 -0
- package/node_modules/@pome-sh/sdk/package.json +7 -3
- package/node_modules/@pome-sh/twin-github/dist/src/access-control.d.ts +3 -3
- package/node_modules/@pome-sh/twin-github/dist/src/checks.d.ts +21 -0
- package/node_modules/@pome-sh/twin-github/dist/src/checks.js +90 -0
- package/node_modules/@pome-sh/twin-github/dist/src/checks.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/checks.d.ts +153 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/checks.js +66 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/checks.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/git.d.ts +567 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/git.js +198 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/git.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/{domain.d.ts → domain/github-domain.d.ts} +340 -71
- package/node_modules/@pome-sh/twin-github/dist/src/domain/github-domain.js +794 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/github-domain.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/helpers.d.ts +5 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/helpers.js +15 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/helpers.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/index.d.ts +2 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/index.js +5 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/index.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/issues.d.ts +545 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/issues.js +272 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/issues.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/pulls.d.ts +816 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/pulls.js +256 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/pulls.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/releases.d.ts +160 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/releases.js +63 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/releases.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/repos.d.ts +219 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/repos.js +131 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/repos.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/search.d.ts +252 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/search.js +83 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/search.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/types.d.ts +15 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/types.js +2 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain/types.js.map +1 -0
- package/node_modules/@pome-sh/twin-github/dist/src/index.d.ts +2 -1
- package/node_modules/@pome-sh/twin-github/dist/src/index.js +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/index.js.map +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/routes.d.ts +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/seed.d.ts +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/serializers.d.ts +3 -3
- package/node_modules/@pome-sh/twin-github/dist/src/tools.d.ts +188 -188
- package/node_modules/@pome-sh/twin-github/dist/src/twin.d.ts +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/twin.js +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/twin.js.map +1 -1
- package/node_modules/@pome-sh/twin-github/package.json +4 -4
- package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/package.json +2 -2
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +35 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/admin-gate.js +103 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/auth.d.ts +100 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/auth.js +262 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/auth.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/build-info.d.ts +7 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/build-info.js +14 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/build-info.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/db.d.ts +44 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/db.js +113 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/db.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/errors.d.ts +24 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/errors.js +61 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/errors.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +43 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/failure-injection.js +160 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +121 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +204 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +8 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/fidelity.js +39 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/fidelity.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/index.d.ts +372 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/index.js +139 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/index.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +10 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +221 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/parity.d.ts +61 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/parity.js +123 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/parity.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/recorder.d.ts +120 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/recorder.js +368 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/recorder.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/redaction.d.ts +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/redaction.js +3 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/redaction.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +54 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/server-helpers.js +181 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/server.d.ts +46 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/server.js +394 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/server.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +8 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/tool-context.js +22 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/dist/tool-context.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/sdk/package.json +54 -0
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/index.d.ts +1 -0
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/index.js +1 -0
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/index.js.map +1 -1
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/shared-types/dist/manifest.d.ts +31 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/shared-types/dist/manifest.js +76 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/shared-types/dist/manifest.js.map +1 -0
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/rest.d.ts +9 -0
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/rest.js +27 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/shared-types/dist/rest.js.map +1 -0
- package/node_modules/@pome-sh/twin-linear/node_modules/@pome-sh/shared-types/manifest-schema.json +68 -0
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/package.json +2 -1
- package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/trace-contract.json +1 -1
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +35 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/admin-gate.js +103 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/auth.d.ts +100 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/auth.js +262 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/auth.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/build-info.d.ts +7 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/build-info.js +14 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/build-info.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/db.d.ts +44 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/db.js +113 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/db.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/errors.d.ts +24 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/errors.js +61 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/errors.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +43 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/failure-injection.js +160 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +121 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +204 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +8 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity.js +39 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/index.d.ts +372 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/index.js +139 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/index.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +10 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +221 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/parity.d.ts +61 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/parity.js +123 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/parity.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/recorder.d.ts +120 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/recorder.js +368 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/recorder.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/redaction.d.ts +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/redaction.js +3 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/redaction.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +54 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server-helpers.js +181 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server.d.ts +46 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server.js +394 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +8 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/tool-context.js +22 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/tool-context.js.map +1 -0
- package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/package.json +54 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +35 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/admin-gate.js +103 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/auth.d.ts +100 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/auth.js +262 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/auth.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/build-info.d.ts +7 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/build-info.js +14 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/build-info.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/db.d.ts +44 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/db.js +113 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/db.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/errors.d.ts +24 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/errors.js +61 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/errors.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +43 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/failure-injection.js +160 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +121 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +204 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +8 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity.js +39 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/index.d.ts +372 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/index.js +139 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/index.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +10 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +221 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/parity.d.ts +61 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/parity.js +123 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/parity.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/recorder.d.ts +120 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/recorder.js +368 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/recorder.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/redaction.d.ts +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/redaction.js +3 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/redaction.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +54 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server-helpers.js +181 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server.d.ts +46 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server.js +394 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +8 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/tool-context.js +22 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/tool-context.js.map +1 -0
- package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/package.json +54 -0
- package/package.json +3 -3
- package/tasks/00-default-seed.md +1 -1
- package/tasks/01-bug-happy-path.md +1 -1
- package/tasks/03-already-triaged.md +1 -1
- package/tasks/06-mislabeled-needs-fix.md +1 -1
- package/tasks/17-in-scope-injection.md +1 -1
- package/node_modules/@pome-sh/twin-github/dist/src/domain.js +0 -0
- package/node_modules/@pome-sh/twin-github/dist/src/domain.js.map +0 -1
- package/node_modules/@pome-sh/twin-github/node_modules/@pome-sh/shared-types/dist/rest.js.map +0 -1
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/admin-gate.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/auth.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/auth.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/auth.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/build-info.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/build-info.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/build-info.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/db.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/db.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/db.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/errors.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/errors.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/errors.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/failure-injection.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/fidelity.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/fidelity.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/index.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/index.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/index.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/parity.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/parity.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/parity.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/recorder.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/recorder.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/recorder.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/redaction.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/redaction.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/redaction.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/server-helpers.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/server.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/server.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/server.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/tool-context.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-gmail}/node_modules/@pome-sh/sdk/dist/tool-context.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/errors.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/errors.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/errors.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/finalize-shapes.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/finalize-shapes.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/finalize-shapes.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/github-access-control.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/github-access-control.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/github-access-control.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/identity.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/identity.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/identity.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/index.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/index.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/index.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/manifest.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/manifest.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/manifest.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/event-schema.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/event-schema.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/event-schema.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/index.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/index.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/index.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/map-span.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/map-span.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/map-span.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/nano.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/nano.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/nano.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/project.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/project.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/project.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/semconv.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/semconv.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/semconv.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/span-event.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/span-event.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/otel/span-event.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/recorder-events.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/recorder-events.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/recorder-events.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/redaction.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/redaction.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/redaction.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/rest.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/rest.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/rest.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/run.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/run.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/run.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/seed-envelope.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/seed-envelope.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/seed-envelope.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/seed-state.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/seed-state.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/seed-state.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/sessions.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/sessions.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/sessions.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/task-vocab.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/task-vocab.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/task-vocab.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/task.d.ts +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/task.js +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/dist/task.js.map +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/manifest-schema.json +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/package.json +0 -0
- /package/node_modules/@pome-sh/{sdk → twin-gmail}/node_modules/@pome-sh/shared-types/trace-contract.json +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/errors.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/errors.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/errors.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/finalize-shapes.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/finalize-shapes.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/finalize-shapes.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/github-access-control.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/github-access-control.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/github-access-control.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/identity.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/identity.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/identity.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/event-schema.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/event-schema.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/event-schema.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/index.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/index.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/index.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/map-span.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/map-span.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/map-span.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/nano.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/nano.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/nano.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/project.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/project.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/project.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/semconv.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/semconv.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/semconv.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/span-event.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/span-event.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/otel/span-event.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/recorder-events.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/recorder-events.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/recorder-events.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/redaction.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/redaction.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/redaction.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/run.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/run.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/run.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/seed-envelope.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/seed-envelope.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/seed-envelope.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/seed-state.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/seed-state.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/seed-state.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/sessions.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/sessions.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/sessions.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/task-vocab.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/task-vocab.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/task-vocab.js.map +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/task.d.ts +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/task.js +0 -0
- /package/node_modules/@pome-sh/{twin-github → twin-linear}/node_modules/@pome-sh/shared-types/dist/task.js.map +0 -0
|
@@ -0,0 +1,256 @@
|
|
|
1
|
+
import { conflict, notFound, validationFailed } from "../errors.js";
|
|
2
|
+
import { nowIso, paginate } from "../util.js";
|
|
3
|
+
import { combinedStatusJson, commitJson, pullRequestDiffText, pullRequestFileJson, pullRequestReviewCommentJson, pullRequestReviewCommentState, pullRequestReviewState, pullRequestState, reviewJson, userJson, } from "../serializers.js";
|
|
4
|
+
import { contentLineCount, normalizePath } from "./helpers.js";
|
|
5
|
+
export function createPullRequest(domain, input, onDelta) {
|
|
6
|
+
const baseRepo = domain.requireRepo(input.owner, input.repo);
|
|
7
|
+
const baseRef = input.base ?? baseRepo.default_branch;
|
|
8
|
+
const number = domain.transaction(() => {
|
|
9
|
+
if (input.head === baseRef || input.head === `${input.owner}:${baseRef}`)
|
|
10
|
+
validationFailed("head", "invalid", input.head);
|
|
11
|
+
const { repo: headRepo, ref: headRef } = domain.resolveHeadRef(baseRepo, input.head);
|
|
12
|
+
const baseBranch = domain.requireBranch(baseRepo.id, baseRef);
|
|
13
|
+
const headBranch = domain.requireBranch(headRepo.id, headRef);
|
|
14
|
+
const duplicate = domain.db.prepare("SELECT * FROM pull_requests WHERE repo_id = ? AND state = 'open' AND head_repo_id = ? AND head_ref = ? AND base_ref = ?").get(baseRepo.id, headRepo.id, headRef, baseRef);
|
|
15
|
+
if (duplicate)
|
|
16
|
+
validationFailed("head", "already_exists", input.head);
|
|
17
|
+
const files = domain.calculatePullFiles(baseRepo, baseRef, headRepo, headRef);
|
|
18
|
+
if (files.length === 0)
|
|
19
|
+
validationFailed("head", "missing_commits", input.head);
|
|
20
|
+
const now = nowIso();
|
|
21
|
+
const pullNumber = domain.nextNumber(baseRepo.id);
|
|
22
|
+
domain.db.prepare("INSERT INTO pull_requests (repo_id, number, title, body, state, user_login, head_repo_id, head_ref, head_sha, base_repo_id, base_ref, base_sha, merged, merge_commit_sha, created_at, updated_at, closed_at, merged_at) VALUES (?, ?, ?, ?, 'open', ?, ?, ?, ?, ?, ?, ?, 0, NULL, ?, ?, NULL, NULL)").run(baseRepo.id, pullNumber, input.title, input.body ?? "", input.actor ?? "pome-agent", headRepo.id, headRef, headBranch.head_sha, baseRepo.id, baseRef, baseBranch.head_sha, now, now);
|
|
23
|
+
domain.replacePullFiles(baseRepo.id, pullNumber, files);
|
|
24
|
+
return pullNumber;
|
|
25
|
+
});
|
|
26
|
+
domain.audit("create_pull_request", baseRepo.full_name, input);
|
|
27
|
+
const createdRow = domain.requirePullRequest(baseRepo.id, number);
|
|
28
|
+
onDelta?.({ before: null, after: pullRequestState(createdRow, baseRepo) });
|
|
29
|
+
return domain.getPullRequest({ owner: input.owner, repo: input.repo, pull_number: number });
|
|
30
|
+
}
|
|
31
|
+
export function listPullRequests(domain, input) {
|
|
32
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
33
|
+
let rows = domain.listPullRequestRows(repo.id);
|
|
34
|
+
if (input.state && input.state !== "all")
|
|
35
|
+
rows = rows.filter((pr) => pr.state === input.state);
|
|
36
|
+
return paginate(rows, input.page, input.per_page ?? input.perPage).map((pr) => domain.serializePullSimple(pr));
|
|
37
|
+
}
|
|
38
|
+
export function getPullRequest(domain, input) {
|
|
39
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
40
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
41
|
+
return domain.serializePull(pr);
|
|
42
|
+
}
|
|
43
|
+
export function getPullRequestFiles(domain, input) {
|
|
44
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
45
|
+
domain.requirePullRequest(repo.id, input.pull_number);
|
|
46
|
+
const rows = domain.listPullRequestFileRows(repo.id, input.pull_number);
|
|
47
|
+
return paginate(rows, input.page, input.per_page ?? input.perPage).map(pullRequestFileJson);
|
|
48
|
+
}
|
|
49
|
+
export function getPullRequestReviews(domain, input) {
|
|
50
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
51
|
+
domain.requirePullRequest(repo.id, input.pull_number);
|
|
52
|
+
const rows = domain.listPullRequestReviewRows(repo.id, input.pull_number);
|
|
53
|
+
return paginate(rows, input.page, input.per_page ?? input.perPage).map((review) => reviewJson(review, repo));
|
|
54
|
+
}
|
|
55
|
+
export function createPullRequestReview(domain, input, onDelta) {
|
|
56
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
57
|
+
const review = domain.transaction(() => {
|
|
58
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
59
|
+
if (pr.state !== "open")
|
|
60
|
+
conflict("Pull request is closed");
|
|
61
|
+
const state = input.event === "APPROVE" ? "APPROVED" : input.event === "REQUEST_CHANGES" ? "CHANGES_REQUESTED" : "COMMENTED";
|
|
62
|
+
const headSha = domain.requireBranch(pr.head_repo_id, pr.head_ref).head_sha;
|
|
63
|
+
const result = domain.db.prepare("INSERT INTO pull_request_reviews (repo_id, pull_number, user_login, state, body, commit_sha, submitted_at) VALUES (?, ?, ?, ?, ?, ?, ?)").run(repo.id, pr.number, "pome-agent", state, input.body ?? "", headSha, nowIso());
|
|
64
|
+
return domain.db.prepare("SELECT * FROM pull_request_reviews WHERE id = ?").get(result.lastInsertRowid);
|
|
65
|
+
});
|
|
66
|
+
domain.audit("create_pull_request_review", repo.full_name, input);
|
|
67
|
+
onDelta?.({ before: null, after: pullRequestReviewState(review, repo) });
|
|
68
|
+
return reviewJson(review, repo);
|
|
69
|
+
}
|
|
70
|
+
export function getPullRequestComments(domain, input) {
|
|
71
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
72
|
+
domain.requirePullRequest(repo.id, input.pull_number);
|
|
73
|
+
const rows = domain.listPullRequestReviewCommentRows(repo.id, input.pull_number);
|
|
74
|
+
return paginate(rows, input.page, input.per_page ?? input.perPage).map((comment) => ({
|
|
75
|
+
id: comment.id,
|
|
76
|
+
path: comment.path,
|
|
77
|
+
body: comment.body,
|
|
78
|
+
user: userJson(comment.user_login),
|
|
79
|
+
created_at: comment.created_at,
|
|
80
|
+
updated_at: comment.updated_at
|
|
81
|
+
}));
|
|
82
|
+
}
|
|
83
|
+
export function getPullRequestStatus(domain, input) {
|
|
84
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
85
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
86
|
+
const head = domain.requireBranch(pr.head_repo_id, pr.head_ref);
|
|
87
|
+
const statuses = head.head_sha ? domain.latestCommitStatuses(pr.head_repo_id, head.head_sha) : [];
|
|
88
|
+
return combinedStatusJson(domain.requireRepoById(pr.head_repo_id), head.head_sha ?? "", statuses);
|
|
89
|
+
}
|
|
90
|
+
export function mergePullRequest(domain, input, onDelta) {
|
|
91
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
92
|
+
let before = null;
|
|
93
|
+
const commit = domain.transaction(() => {
|
|
94
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
95
|
+
before = pullRequestState(pr, repo);
|
|
96
|
+
if (pr.state !== "open")
|
|
97
|
+
conflict("Pull request is closed");
|
|
98
|
+
if (pr.merged)
|
|
99
|
+
conflict("Pull request already merged");
|
|
100
|
+
const status = domain.getPullRequestStatus(input);
|
|
101
|
+
if (status.state === "failure")
|
|
102
|
+
conflict("Required status check failed");
|
|
103
|
+
const headRepo = domain.requireRepoById(pr.head_repo_id);
|
|
104
|
+
const files = domain.listPullRequestFileRows(repo.id, pr.number);
|
|
105
|
+
const changes = files.map((file) => {
|
|
106
|
+
if (file.status === "removed")
|
|
107
|
+
return { path: file.filename, content: "", delete: true };
|
|
108
|
+
const source = domain.getFile(headRepo.id, pr.head_ref, file.filename);
|
|
109
|
+
if (!source)
|
|
110
|
+
validationFailed("files", "missing", file.filename);
|
|
111
|
+
return { path: file.filename, content: source.content };
|
|
112
|
+
});
|
|
113
|
+
const mergedCommit = domain.commitFiles(repo, pr.base_ref, input.commit_title ?? `Merge pull request #${pr.number}`, changes, "pome-agent");
|
|
114
|
+
const now = nowIso();
|
|
115
|
+
domain.db.prepare("UPDATE pull_requests SET state = 'closed', merged = 1, merge_commit_sha = ?, updated_at = ?, closed_at = ?, merged_at = ? WHERE repo_id = ? AND number = ?").run(mergedCommit.sha, now, now, now, repo.id, pr.number);
|
|
116
|
+
return mergedCommit;
|
|
117
|
+
});
|
|
118
|
+
domain.audit("merge_pull_request", repo.full_name, input);
|
|
119
|
+
const merged = domain.requirePullRequest(repo.id, input.pull_number);
|
|
120
|
+
onDelta?.({ before, after: pullRequestState(merged, repo) });
|
|
121
|
+
return { sha: commit.sha, merged: true, message: "Pull Request successfully merged" };
|
|
122
|
+
}
|
|
123
|
+
export function updatePullRequestBranch(domain, input, onDelta) {
|
|
124
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
125
|
+
let before = null;
|
|
126
|
+
const pullNumber = domain.transaction(() => {
|
|
127
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
128
|
+
before = pullRequestState(pr, repo);
|
|
129
|
+
if (pr.state !== "open")
|
|
130
|
+
conflict("Pull request is closed");
|
|
131
|
+
const headRepo = domain.requireRepoById(pr.head_repo_id);
|
|
132
|
+
const headBranch = domain.requireBranch(headRepo.id, pr.head_ref);
|
|
133
|
+
if (input.expected_head_sha && headBranch.head_sha !== input.expected_head_sha)
|
|
134
|
+
conflict("Head SHA did not match");
|
|
135
|
+
const baseBranch = domain.requireBranch(repo.id, pr.base_ref);
|
|
136
|
+
// Semantic merge (F-735): merge base into head with a real merge commit
|
|
137
|
+
// instead of resetting the head pointer to the base head. No-op when the
|
|
138
|
+
// head branch already contains the base head (GitHub returns 422 there;
|
|
139
|
+
// documented deviation).
|
|
140
|
+
const mergeBase = domain.findMergeBase(repo, baseBranch.head_sha, headRepo, headBranch.head_sha);
|
|
141
|
+
if (baseBranch.head_sha === mergeBase)
|
|
142
|
+
return pr.number;
|
|
143
|
+
const changes = domain.mergeChangesFromBase(repo, pr.base_ref, headRepo, pr.head_ref, mergeBase);
|
|
144
|
+
// Single-parent commit model: a previous merge is invisible to the
|
|
145
|
+
// ancestry walk, so "base already merged" surfaces as an empty change
|
|
146
|
+
// set. Merge commits are only created when they change files on head.
|
|
147
|
+
if (changes.length === 0)
|
|
148
|
+
return pr.number;
|
|
149
|
+
const mergeCommit = domain.commitFiles(headRepo, pr.head_ref, `Merge branch '${pr.base_ref}' into ${pr.head_ref}`, changes, "pome-agent");
|
|
150
|
+
domain.db.prepare("UPDATE pull_requests SET head_sha = ?, updated_at = ? WHERE repo_id = ? AND number = ?").run(mergeCommit.sha, nowIso(), repo.id, pr.number);
|
|
151
|
+
domain.replacePullFiles(repo.id, pr.number, domain.calculatePullFiles(repo, pr.base_ref, headRepo, pr.head_ref));
|
|
152
|
+
return pr.number;
|
|
153
|
+
});
|
|
154
|
+
domain.audit("update_pull_request_branch", repo.full_name, input);
|
|
155
|
+
const updated = domain.requirePullRequest(repo.id, pullNumber);
|
|
156
|
+
onDelta?.({ before, after: pullRequestState(updated, repo) });
|
|
157
|
+
return { message: "Updating pull request branch.", url: `https://api.github.com/repos/${repo.full_name}/pulls/${pullNumber}/update-branch` };
|
|
158
|
+
}
|
|
159
|
+
export function getPullRequestDiff(domain, input) {
|
|
160
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
161
|
+
domain.requirePullRequest(repo.id, input.pull_number);
|
|
162
|
+
const files = domain.listPullRequestFileRows(repo.id, input.pull_number);
|
|
163
|
+
return { diff: pullRequestDiffText(files) };
|
|
164
|
+
}
|
|
165
|
+
// Cluster C — pull requests deeper ---------------------------------------
|
|
166
|
+
export function updatePullRequest(domain, input, onDelta) {
|
|
167
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
168
|
+
let before = null;
|
|
169
|
+
domain.transaction(() => {
|
|
170
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
171
|
+
before = pullRequestState(pr, repo);
|
|
172
|
+
if (pr.merged && (input.state === "open" || (input.base !== undefined && input.base !== pr.base_ref))) {
|
|
173
|
+
conflict("Cannot reopen or rebase a merged pull request");
|
|
174
|
+
}
|
|
175
|
+
const nextBase = input.base ?? pr.base_ref;
|
|
176
|
+
if (nextBase !== pr.base_ref)
|
|
177
|
+
domain.requireBranch(repo.id, nextBase);
|
|
178
|
+
const nextState = input.state ?? pr.state;
|
|
179
|
+
const closedAt = nextState === "closed" && pr.state !== "closed" ? nowIso() : nextState === "open" ? null : pr.closed_at;
|
|
180
|
+
const now = nowIso();
|
|
181
|
+
domain.db.prepare("UPDATE pull_requests SET title = ?, body = ?, state = ?, base_ref = ?, updated_at = ?, closed_at = ? WHERE repo_id = ? AND number = ?").run(input.title ?? pr.title, input.body ?? pr.body, nextState, nextBase, now, closedAt, repo.id, pr.number);
|
|
182
|
+
if (nextBase !== pr.base_ref) {
|
|
183
|
+
const headRepo = domain.requireRepoById(pr.head_repo_id);
|
|
184
|
+
domain.replacePullFiles(repo.id, pr.number, domain.calculatePullFiles(repo, nextBase, headRepo, pr.head_ref));
|
|
185
|
+
const baseBranch = domain.requireBranch(repo.id, nextBase);
|
|
186
|
+
domain.db.prepare("UPDATE pull_requests SET base_sha = ? WHERE repo_id = ? AND number = ?").run(baseBranch.head_sha, repo.id, pr.number);
|
|
187
|
+
}
|
|
188
|
+
});
|
|
189
|
+
domain.audit("update_pull_request", repo.full_name, input);
|
|
190
|
+
const updated = domain.requirePullRequest(repo.id, input.pull_number);
|
|
191
|
+
onDelta?.({ before, after: pullRequestState(updated, repo) });
|
|
192
|
+
return domain.getPullRequest({ owner: input.owner, repo: input.repo, pull_number: input.pull_number });
|
|
193
|
+
}
|
|
194
|
+
export function getPullRequestCommits(domain, input) {
|
|
195
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
196
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
197
|
+
const headRepo = domain.requireRepoById(pr.head_repo_id);
|
|
198
|
+
const headSha = domain.getBranch(headRepo.id, pr.head_ref)?.head_sha ?? pr.head_sha;
|
|
199
|
+
const baseSha = domain.getBranch(repo.id, pr.base_ref)?.head_sha ?? pr.base_sha;
|
|
200
|
+
const commits = headSha ? domain.commitsBetween(headRepo.id, headSha, baseSha) : [];
|
|
201
|
+
// GitHub returns oldest-first for PR commits — reverse the ancestry walk.
|
|
202
|
+
const ordered = [...commits].reverse();
|
|
203
|
+
return paginate(ordered, input.page, input.per_page ?? input.perPage).map((commit) => commitJson(commit, headRepo));
|
|
204
|
+
}
|
|
205
|
+
export function createPullRequestReviewComment(domain, input, options = {}, onDelta) {
|
|
206
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
207
|
+
const comment = domain.transaction(() => {
|
|
208
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
209
|
+
if (!input.body.trim())
|
|
210
|
+
validationFailed("body", "missing");
|
|
211
|
+
if (!input.line)
|
|
212
|
+
validationFailed("line", "missing");
|
|
213
|
+
const path = normalizePath(input.path);
|
|
214
|
+
const prFile = domain.listPullRequestFileRows(repo.id, pr.number).find((file) => file.filename === path);
|
|
215
|
+
if (!prFile)
|
|
216
|
+
validationFailed("path", "not_in_pr", path);
|
|
217
|
+
const side = input.side ?? "RIGHT";
|
|
218
|
+
const headRepo = domain.requireRepoById(pr.head_repo_id);
|
|
219
|
+
const targetRepo = side === "LEFT" ? domain.requireRepoById(pr.base_repo_id) : headRepo;
|
|
220
|
+
const targetRef = side === "LEFT" ? pr.base_ref : pr.head_ref;
|
|
221
|
+
const targetFile = domain.getFile(targetRepo.id, targetRef, path);
|
|
222
|
+
if (!targetFile || input.line > contentLineCount(targetFile.content))
|
|
223
|
+
validationFailed("line", "invalid", input.line);
|
|
224
|
+
const headSha = domain.getBranch(pr.head_repo_id, pr.head_ref)?.head_sha ?? pr.head_sha;
|
|
225
|
+
const baseSha = domain.getBranch(repo.id, pr.base_ref)?.head_sha ?? pr.base_sha;
|
|
226
|
+
const commits = headSha ? domain.commitsBetween(headRepo.id, headSha, baseSha) : [];
|
|
227
|
+
const commitSha = input.commit_id ?? headSha;
|
|
228
|
+
if (!commitSha || !commits.some((commit) => commit.sha === commitSha)) {
|
|
229
|
+
validationFailed("commit_id", "invalid", input.commit_id ?? commitSha ?? "");
|
|
230
|
+
}
|
|
231
|
+
const now = nowIso();
|
|
232
|
+
const result = domain.db.prepare("INSERT INTO pull_request_review_comments (repo_id, pull_number, path, body, user_login, created_at, updated_at, line, side, commit_sha, in_reply_to_id) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, NULL)").run(repo.id, pr.number, path, input.body, options.actor ?? "pome-agent", now, now, input.line ?? null, side, commitSha);
|
|
233
|
+
return domain.db.prepare("SELECT * FROM pull_request_review_comments WHERE id = ?").get(result.lastInsertRowid);
|
|
234
|
+
});
|
|
235
|
+
domain.audit("create_pull_request_review_comment", repo.full_name, input);
|
|
236
|
+
onDelta?.({ before: null, after: pullRequestReviewCommentState(comment, repo) });
|
|
237
|
+
return pullRequestReviewCommentJson(comment, repo);
|
|
238
|
+
}
|
|
239
|
+
export function addReplyToPullRequestComment(domain, input, options = {}, onDelta) {
|
|
240
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
241
|
+
const reply = domain.transaction(() => {
|
|
242
|
+
const pr = domain.requirePullRequest(repo.id, input.pull_number);
|
|
243
|
+
const parent = domain.db.prepare("SELECT * FROM pull_request_review_comments WHERE id = ? AND repo_id = ? AND pull_number = ?").get(input.comment_id, repo.id, pr.number);
|
|
244
|
+
if (!parent)
|
|
245
|
+
notFound("Review comment not found");
|
|
246
|
+
if (!input.body.trim())
|
|
247
|
+
validationFailed("body", "missing");
|
|
248
|
+
const now = nowIso();
|
|
249
|
+
const result = domain.db.prepare("INSERT INTO pull_request_review_comments (repo_id, pull_number, path, body, user_login, created_at, updated_at, line, side, commit_sha, in_reply_to_id) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)").run(repo.id, pr.number, parent.path, input.body, options.actor ?? "pome-agent", now, now, parent.line, parent.side, parent.commit_sha, parent.id);
|
|
250
|
+
return domain.db.prepare("SELECT * FROM pull_request_review_comments WHERE id = ?").get(result.lastInsertRowid);
|
|
251
|
+
});
|
|
252
|
+
domain.audit("add_reply_to_pull_request_comment", repo.full_name, input);
|
|
253
|
+
onDelta?.({ before: null, after: pullRequestReviewCommentState(reply, repo) });
|
|
254
|
+
return pullRequestReviewCommentJson(reply, repo);
|
|
255
|
+
}
|
|
256
|
+
//# sourceMappingURL=pulls.js.map
|
|
@@ -0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C,CAAC,CAAC;IACH,MAAM,CAAC,KAAK,CAAC,mCAAmC,EAAE,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC,CAAC;IACzE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,6BAA6B,CAAC,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC;IAC/E,OAAO,4BAA4B,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;AACnD,CAAC"}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import type { GitHubDomain } from "./github-domain.js";
|
|
2
|
+
import type { MutatingOptions, PageOptions, StateDeltaCallback } from "./types.js";
|
|
3
|
+
export declare function listTags(domain: GitHubDomain, input: {
|
|
4
|
+
owner: string;
|
|
5
|
+
repo: string;
|
|
6
|
+
} & PageOptions): {
|
|
7
|
+
name: string;
|
|
8
|
+
commit: {
|
|
9
|
+
sha: string;
|
|
10
|
+
url: string;
|
|
11
|
+
};
|
|
12
|
+
zipball_url: string;
|
|
13
|
+
tarball_url: string;
|
|
14
|
+
node_id: string;
|
|
15
|
+
}[];
|
|
16
|
+
export declare function listReleases(domain: GitHubDomain, input: {
|
|
17
|
+
owner: string;
|
|
18
|
+
repo: string;
|
|
19
|
+
} & PageOptions): {
|
|
20
|
+
id: number;
|
|
21
|
+
node_id: string;
|
|
22
|
+
tag_name: string;
|
|
23
|
+
target_commitish: string;
|
|
24
|
+
name: string | null;
|
|
25
|
+
body: string;
|
|
26
|
+
draft: boolean;
|
|
27
|
+
prerelease: boolean;
|
|
28
|
+
author: {
|
|
29
|
+
login: string;
|
|
30
|
+
id: number;
|
|
31
|
+
node_id: string;
|
|
32
|
+
avatar_url: string;
|
|
33
|
+
html_url: string;
|
|
34
|
+
type: "User" | "Organization";
|
|
35
|
+
site_admin: false;
|
|
36
|
+
};
|
|
37
|
+
created_at: string;
|
|
38
|
+
published_at: string | null;
|
|
39
|
+
html_url: string;
|
|
40
|
+
url: string;
|
|
41
|
+
assets_url: string;
|
|
42
|
+
upload_url: string;
|
|
43
|
+
tarball_url: string;
|
|
44
|
+
zipball_url: string;
|
|
45
|
+
assets: never[];
|
|
46
|
+
}[];
|
|
47
|
+
export declare function getLatestRelease(domain: GitHubDomain, input: {
|
|
48
|
+
owner: string;
|
|
49
|
+
repo: string;
|
|
50
|
+
}): {
|
|
51
|
+
id: number;
|
|
52
|
+
node_id: string;
|
|
53
|
+
tag_name: string;
|
|
54
|
+
target_commitish: string;
|
|
55
|
+
name: string | null;
|
|
56
|
+
body: string;
|
|
57
|
+
draft: boolean;
|
|
58
|
+
prerelease: boolean;
|
|
59
|
+
author: {
|
|
60
|
+
login: string;
|
|
61
|
+
id: number;
|
|
62
|
+
node_id: string;
|
|
63
|
+
avatar_url: string;
|
|
64
|
+
html_url: string;
|
|
65
|
+
type: "User" | "Organization";
|
|
66
|
+
site_admin: false;
|
|
67
|
+
};
|
|
68
|
+
created_at: string;
|
|
69
|
+
published_at: string | null;
|
|
70
|
+
html_url: string;
|
|
71
|
+
url: string;
|
|
72
|
+
assets_url: string;
|
|
73
|
+
upload_url: string;
|
|
74
|
+
tarball_url: string;
|
|
75
|
+
zipball_url: string;
|
|
76
|
+
assets: never[];
|
|
77
|
+
};
|
|
78
|
+
export declare function getReleaseByTag(domain: GitHubDomain, input: {
|
|
79
|
+
owner: string;
|
|
80
|
+
repo: string;
|
|
81
|
+
tag: string;
|
|
82
|
+
}): {
|
|
83
|
+
id: number;
|
|
84
|
+
node_id: string;
|
|
85
|
+
tag_name: string;
|
|
86
|
+
target_commitish: string;
|
|
87
|
+
name: string | null;
|
|
88
|
+
body: string;
|
|
89
|
+
draft: boolean;
|
|
90
|
+
prerelease: boolean;
|
|
91
|
+
author: {
|
|
92
|
+
login: string;
|
|
93
|
+
id: number;
|
|
94
|
+
node_id: string;
|
|
95
|
+
avatar_url: string;
|
|
96
|
+
html_url: string;
|
|
97
|
+
type: "User" | "Organization";
|
|
98
|
+
site_admin: false;
|
|
99
|
+
};
|
|
100
|
+
created_at: string;
|
|
101
|
+
published_at: string | null;
|
|
102
|
+
html_url: string;
|
|
103
|
+
url: string;
|
|
104
|
+
assets_url: string;
|
|
105
|
+
upload_url: string;
|
|
106
|
+
tarball_url: string;
|
|
107
|
+
zipball_url: string;
|
|
108
|
+
assets: never[];
|
|
109
|
+
};
|
|
110
|
+
export declare function getTag(domain: GitHubDomain, input: {
|
|
111
|
+
owner: string;
|
|
112
|
+
repo: string;
|
|
113
|
+
tag: string;
|
|
114
|
+
}): {
|
|
115
|
+
name: string;
|
|
116
|
+
commit: {
|
|
117
|
+
sha: string;
|
|
118
|
+
url: string;
|
|
119
|
+
};
|
|
120
|
+
zipball_url: string;
|
|
121
|
+
tarball_url: string;
|
|
122
|
+
node_id: string;
|
|
123
|
+
};
|
|
124
|
+
export declare function createRelease(domain: GitHubDomain, input: {
|
|
125
|
+
owner: string;
|
|
126
|
+
repo: string;
|
|
127
|
+
tag_name: string;
|
|
128
|
+
target_commitish?: string;
|
|
129
|
+
name?: string;
|
|
130
|
+
body?: string;
|
|
131
|
+
draft?: boolean;
|
|
132
|
+
prerelease?: boolean;
|
|
133
|
+
}, options?: MutatingOptions, onDelta?: StateDeltaCallback): {
|
|
134
|
+
id: number;
|
|
135
|
+
node_id: string;
|
|
136
|
+
tag_name: string;
|
|
137
|
+
target_commitish: string;
|
|
138
|
+
name: string | null;
|
|
139
|
+
body: string;
|
|
140
|
+
draft: boolean;
|
|
141
|
+
prerelease: boolean;
|
|
142
|
+
author: {
|
|
143
|
+
login: string;
|
|
144
|
+
id: number;
|
|
145
|
+
node_id: string;
|
|
146
|
+
avatar_url: string;
|
|
147
|
+
html_url: string;
|
|
148
|
+
type: "User" | "Organization";
|
|
149
|
+
site_admin: false;
|
|
150
|
+
};
|
|
151
|
+
created_at: string;
|
|
152
|
+
published_at: string | null;
|
|
153
|
+
html_url: string;
|
|
154
|
+
url: string;
|
|
155
|
+
assets_url: string;
|
|
156
|
+
upload_url: string;
|
|
157
|
+
tarball_url: string;
|
|
158
|
+
zipball_url: string;
|
|
159
|
+
assets: never[];
|
|
160
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { notFound, validationFailed } from "../errors.js";
|
|
2
|
+
import { nowIso, paginate } from "../util.js";
|
|
3
|
+
import { releaseJson, releaseState, tagJson, } from "../serializers.js";
|
|
4
|
+
// Cluster G — tags & releases --------------------------------------------
|
|
5
|
+
export function listTags(domain, input) {
|
|
6
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
7
|
+
const rows = domain.db.prepare("SELECT * FROM tags WHERE repo_id = ? ORDER BY created_at DESC").all(repo.id);
|
|
8
|
+
return paginate(rows, input.page, input.per_page ?? input.perPage).map((tag) => tagJson(tag, repo));
|
|
9
|
+
}
|
|
10
|
+
export function listReleases(domain, input) {
|
|
11
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
12
|
+
const rows = domain.db.prepare("SELECT * FROM releases WHERE repo_id = ? ORDER BY created_at DESC").all(repo.id);
|
|
13
|
+
return paginate(rows, input.page, input.per_page ?? input.perPage).map((release) => releaseJson(release, repo));
|
|
14
|
+
}
|
|
15
|
+
export function getLatestRelease(domain, input) {
|
|
16
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
17
|
+
const row = domain.db.prepare("SELECT * FROM releases WHERE repo_id = ? AND draft = 0 AND prerelease = 0 AND published_at IS NOT NULL ORDER BY published_at DESC LIMIT 1").get(repo.id);
|
|
18
|
+
if (!row)
|
|
19
|
+
notFound("Not Found");
|
|
20
|
+
return releaseJson(row, repo);
|
|
21
|
+
}
|
|
22
|
+
export function getReleaseByTag(domain, input) {
|
|
23
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
24
|
+
const row = domain.db.prepare("SELECT * FROM releases WHERE repo_id = ? AND tag_name = ?").get(repo.id, input.tag);
|
|
25
|
+
if (!row)
|
|
26
|
+
notFound("Not Found");
|
|
27
|
+
return releaseJson(row, repo);
|
|
28
|
+
}
|
|
29
|
+
export function getTag(domain, input) {
|
|
30
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
31
|
+
const row = domain.db.prepare("SELECT * FROM tags WHERE repo_id = ? AND name = ?").get(repo.id, input.tag);
|
|
32
|
+
if (!row)
|
|
33
|
+
notFound("Not Found");
|
|
34
|
+
return tagJson(row, repo);
|
|
35
|
+
}
|
|
36
|
+
export function createRelease(domain, input, options = {}, onDelta) {
|
|
37
|
+
const repo = domain.requireRepo(input.owner, input.repo);
|
|
38
|
+
const release = domain.transaction(() => {
|
|
39
|
+
if (!input.tag_name.trim())
|
|
40
|
+
validationFailed("tag_name", "missing");
|
|
41
|
+
const existingRelease = domain.db.prepare("SELECT id FROM releases WHERE repo_id = ? AND tag_name = ?").get(repo.id, input.tag_name);
|
|
42
|
+
if (existingRelease)
|
|
43
|
+
validationFailed("tag_name", "already_exists", input.tag_name);
|
|
44
|
+
const target = input.target_commitish ?? repo.default_branch;
|
|
45
|
+
let tag = domain.db.prepare("SELECT * FROM tags WHERE repo_id = ? AND name = ?").get(repo.id, input.tag_name);
|
|
46
|
+
if (!tag) {
|
|
47
|
+
// Auto-create tag from target_commitish (branch name or SHA).
|
|
48
|
+
const sha = domain.resolveRefToSha(repo, target);
|
|
49
|
+
const now = nowIso();
|
|
50
|
+
domain.db.prepare("INSERT INTO tags (repo_id, name, commit_sha, created_at) VALUES (?, ?, ?, ?)").run(repo.id, input.tag_name, sha, now);
|
|
51
|
+
tag = { repo_id: repo.id, name: input.tag_name, commit_sha: sha, created_at: now };
|
|
52
|
+
}
|
|
53
|
+
const draft = input.draft ? 1 : 0;
|
|
54
|
+
const prerelease = input.prerelease ? 1 : 0;
|
|
55
|
+
const now = nowIso();
|
|
56
|
+
const result = domain.db.prepare("INSERT INTO releases (repo_id, tag_name, target_commitish, name, body, draft, prerelease, author_login, created_at, published_at) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)").run(repo.id, input.tag_name, target, input.name ?? null, input.body ?? "", draft, prerelease, options.actor ?? "pome-agent", now, draft ? null : now);
|
|
57
|
+
return domain.db.prepare("SELECT * FROM releases WHERE id = ?").get(result.lastInsertRowid);
|
|
58
|
+
});
|
|
59
|
+
domain.audit("create_release", repo.full_name, input);
|
|
60
|
+
onDelta?.({ before: null, after: releaseState(release, repo) });
|
|
61
|
+
return releaseJson(release, repo);
|
|
62
|
+
}
|
|
63
|
+
//# sourceMappingURL=releases.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"releases.js","sourceRoot":"","sources":["../../../src/domain/releases.ts"],"names":[],"mappings":"AAoBA,OAAO,EAAY,QAAQ,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,EAAkC,MAAM,EAAE,QAAQ,EAA4B,MAAM,YAAY,CAAC;AACxG,OAAO,EAgCL,WAAW,EACX,YAAY,EAKZ,OAAO,GAER,MAAM,mBAAmB,CAAC;AAI3B,2EAA2E;AAE3E,MAAM,UAAU,QAAQ,CAAC,MAAoB,EAAE,KAAoD;IACjG,MAAM,IAAI,GAAG,MAAM,CAAC,WAAW,CAAC,KAAK,CAAC,KAAK,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;IACzD,MAAM,IAAI,GAAG,MAAM,CAAC,EAAE,CAAC,OAAO,CAAC,+DAA+D,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAa,CAAC;IACzH,OAAO,QAAQ,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,QAAQ,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,CAAC;AACtG,CAAC;AAGD,MAAM,UAAU,YAAY,CAAC,MAAoB,EAAE,KAAoD;IACrG,MAAM,IAAI,GAAG,MAAM,CAAC,WAAW,CAAC,KAAK,CAAC,KAAK,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC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