@open-agent-toolkit/cli 0.1.18 → 0.1.20
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/README.md +2 -1
- package/assets/docs/cli-utilities/config-and-local-state.md +1 -1
- package/assets/docs/cli-utilities/configuration.md +5 -5
- package/assets/docs/reference/cli-reference.md +7 -5
- package/assets/docs/reference/file-locations.md +1 -1
- package/assets/docs/reference/oat-directory-structure.md +3 -3
- package/assets/docs/workflows/projects/index.md +1 -1
- package/assets/docs/workflows/projects/lifecycle.md +1 -1
- package/assets/docs/workflows/projects/repo-analysis.md +7 -4
- package/assets/public-package-versions.json +4 -4
- package/assets/skills/oat-agent-instructions-apply/SKILL.md +4 -2
- package/assets/skills/oat-agent-instructions-apply/references/instruction-file-templates/frontmatter/canonical-rule.md +93 -0
- package/assets/skills/oat-project-complete/SKILL.md +16 -152
- package/assets/skills/oat-wrap-up/SKILL.md +9 -9
- package/assets/skills/oat-wrap-up/references/automation-recipes.md +5 -5
- package/dist/commands/config/index.js +2 -2
- package/dist/commands/project/archive/archive-utils.d.ts +19 -0
- package/dist/commands/project/archive/archive-utils.d.ts.map +1 -1
- package/dist/commands/project/archive/archive-utils.js +94 -25
- package/dist/commands/project/archive/index.d.ts +6 -19
- package/dist/commands/project/archive/index.d.ts.map +1 -1
- package/dist/commands/project/archive/index.js +19 -251
- package/dist/commands/project/archive/push-runner.d.ts +21 -0
- package/dist/commands/project/archive/push-runner.d.ts.map +1 -0
- package/dist/commands/project/archive/push-runner.js +151 -0
- package/dist/commands/project/archive/sync-runner.d.ts +47 -0
- package/dist/commands/project/archive/sync-runner.d.ts.map +1 -0
- package/dist/commands/project/archive/sync-runner.js +232 -0
- package/dist/commands/repo/archive/index.d.ts +4 -0
- package/dist/commands/repo/archive/index.d.ts.map +1 -0
- package/dist/commands/repo/archive/index.js +22 -0
- package/dist/commands/repo/index.d.ts.map +1 -1
- package/dist/commands/repo/index.js +2 -0
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -36,7 +36,8 @@ Additional useful entry points:
|
|
|
36
36
|
- `oat project status --json`
|
|
37
37
|
- `oat project list --json`
|
|
38
38
|
- `oat project complete-state /path/to/project`
|
|
39
|
-
- `oat project archive
|
|
39
|
+
- `oat project archive /path/to/project`
|
|
40
|
+
- `oat repo archive sync`
|
|
40
41
|
- `oat doctor`
|
|
41
42
|
|
|
42
43
|
## Inspection Commands
|
|
@@ -62,7 +62,7 @@ Archive lifecycle settings live here as shared repo config:
|
|
|
62
62
|
- `archive.awsProfile`
|
|
63
63
|
- `archive.awsRegion`
|
|
64
64
|
|
|
65
|
-
`archive.awsProfile` and `archive.awsRegion` are forwarded as `AWS_PROFILE` / `AWS_REGION` env vars into every `aws` spawn that runs during `oat-project-complete` and `oat
|
|
65
|
+
`archive.awsProfile` and `archive.awsRegion` are forwarded as `AWS_PROFILE` / `AWS_REGION` env vars into every `aws` spawn that runs during `oat-project-complete` and `oat repo archive sync`, and they override any values already set in the parent shell — the repo's archive-scoped declaration wins so users don't have to remember to unset `AWS_PROFILE` per shell. The per-invocation `oat repo archive sync --profile <profile>` and `--region <region>` flags then override the config for a single run, giving precedence `flag > config > shell env`. When neither flag nor config is set, the parent shell's `AWS_PROFILE` / `AWS_REGION` pass through unchanged. Raw access keys (`AWS_ACCESS_KEY_ID` / `AWS_SECRET_ACCESS_KEY`) remain a shell-environment concern — there is no config plumbing for them.
|
|
66
66
|
|
|
67
67
|
Tool-pack installation state also lives here as shared repo config:
|
|
68
68
|
|
|
@@ -112,7 +112,7 @@ With those values configured:
|
|
|
112
112
|
- `oat-project-complete` still archives locally into `.oat/projects/archived/<project>/`
|
|
113
113
|
- completion also attempts an S3 upload when AWS CLI is available and configured, storing dated snapshots such as `<archive.s3Uri>/<repo-slug>/projects/20260401-my-project/`
|
|
114
114
|
- completion also copies `summary.md` into `<archive.summaryExportPath>/20260401-my-project.md`
|
|
115
|
-
- `oat
|
|
115
|
+
- `oat repo archive sync` can later pull archive data back down from S3 and materialize the latest snapshot into the local bare archive path `.oat/projects/archived/<project>/`
|
|
116
116
|
- `oat-wrap-up` can write tracked reports into `<archive.wrapUpExportPath>/YYYY-MM-DD-wrap-up-<label>.md`; if the key is unset, the skill uses `.oat/repo/reference/wrap-ups/`
|
|
117
117
|
- every `aws` spawn (preflight `aws sts get-caller-identity`, `aws s3 ls`, `aws s3 sync`) runs with `AWS_PROFILE` / `AWS_REGION` set from `archive.awsProfile` / `archive.awsRegion` when configured, overriding any value already in the parent shell
|
|
118
118
|
|
|
@@ -120,7 +120,7 @@ With those values configured:
|
|
|
120
120
|
|
|
121
121
|
Profile and region resolve with the following precedence per `aws` invocation, highest first:
|
|
122
122
|
|
|
123
|
-
1. CLI flag passed to `oat
|
|
123
|
+
1. CLI flag passed to `oat repo archive sync` (`--profile <profile>`, `--region <region>`)
|
|
124
124
|
2. The repo's shared `archive.awsProfile` / `archive.awsRegion` config
|
|
125
125
|
3. The parent shell's existing `AWS_PROFILE` / `AWS_REGION` env vars
|
|
126
126
|
|
|
@@ -128,15 +128,15 @@ If none of the three are present for a given var, OAT does not inject it — the
|
|
|
128
128
|
|
|
129
129
|
`archive.awsProfile` is treated as deliberate, OAT-archive-scoped intent: if the repo declares the identity it wants to archive under, that value wins over whatever profile happens to be in the calling shell. Use `--profile` for one-off overrides; clear `archive.awsProfile` (set it to an empty string) to fall back to shell `AWS_PROFILE`.
|
|
130
130
|
|
|
131
|
-
The `oat
|
|
131
|
+
The `oat repo archive sync` flags only override for that single invocation:
|
|
132
132
|
|
|
133
133
|
```bash
|
|
134
|
-
oat
|
|
134
|
+
oat repo archive sync --profile work-sso --region us-east-1
|
|
135
135
|
```
|
|
136
136
|
|
|
137
137
|
`oat-project-complete` does not accept per-invocation flags. Set the shared config (or your shell env) ahead of time if completion needs a specific profile.
|
|
138
138
|
|
|
139
|
-
Raw access keys (`AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, and friends) remain a shell-environment concern. OAT does not expose config keys for them — set them in your shell before running `oat-project-complete` or `oat
|
|
139
|
+
Raw access keys (`AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, and friends) remain a shell-environment concern. OAT does not expose config keys for them — set them in your shell before running `oat-project-complete` or `oat repo archive sync` and they are inherited by the spawned `aws` process unchanged.
|
|
140
140
|
|
|
141
141
|
## Repo-local and user state
|
|
142
142
|
|
|
@@ -7,7 +7,7 @@ description: Scannable reference for the current OAT CLI surface, with links to
|
|
|
7
7
|
|
|
8
8
|
Use this page when you need a quick map of the OAT CLI rather than the full command-by-command docs. It is intentionally shallow: each section points to the owning page that documents the detailed behavior.
|
|
9
9
|
|
|
10
|
-
The CLI is also a standalone value path. You can use `oat init`, `oat sync`, `oat tools`, docs commands, and repo-analysis commands without adopting the full project workflow.
|
|
10
|
+
The CLI is also a standalone value path. You can use `oat init`, `oat sync`, `oat tools`, docs commands, repo archive sync, and repo-analysis commands without adopting the full project workflow.
|
|
11
11
|
|
|
12
12
|
## Contents
|
|
13
13
|
|
|
@@ -18,7 +18,7 @@ The CLI is also a standalone value path. You can use `oat init`, `oat sync`, `oa
|
|
|
18
18
|
- [Provider Sync](../provider-sync/index.md) - Sync behavior, provider capabilities, config, and drift management.
|
|
19
19
|
- [Agentic Workflows](../workflows/index.md) - Tracked project execution, skills, ideas, and workflow routing.
|
|
20
20
|
- [Workflow & Projects](../workflows/projects/index.md) - Project lifecycle, artifacts, reviews, PR flow, and state-machine docs.
|
|
21
|
-
- [Repository Analysis](../workflows/projects/repo-analysis.md) - Detailed `oat repo pr-comments ...` behavior.
|
|
21
|
+
- [Repository PR Comment Analysis](../workflows/projects/repo-analysis.md) - Detailed `oat repo pr-comments ...` behavior.
|
|
22
22
|
|
|
23
23
|
## Command Groups
|
|
24
24
|
|
|
@@ -32,10 +32,10 @@ The CLI is also a standalone value path. You can use `oat init`, `oat sync`, `oa
|
|
|
32
32
|
| `oat state ...` / `oat index ...` / `internal` | Repo dashboard refresh, repo indexing, validation helpers, and diagnostics. | [Config and Local State](../cli-utilities/config-and-local-state.md) |
|
|
33
33
|
| `oat docs ...` | Docs app bootstrap, migration, index generation, nav sync, and docs workflow entrypoints. | [Docs Tooling Commands](../docs-tooling/commands.md) |
|
|
34
34
|
| `oat status` / `oat sync` / `oat providers ...` | Provider sync, drift inspection, provider configuration, and adoption behavior. | [Provider Sync](../provider-sync/index.md) |
|
|
35
|
-
| `oat project ...` / `oat cleanup ...` | Project scaffolding, active-project status inspection, tracked-project listing, plan validation, and project/artifact cleanup commands. | [Workflow & Projects](../workflows/projects/index.md) |
|
|
36
|
-
| `oat repo ...` | Repository-level
|
|
35
|
+
| `oat project ...` / `oat cleanup ...` | Project scaffolding, active-project status inspection, tracked-project listing, plan validation, archive creation, and project/artifact cleanup commands. | [Workflow & Projects](../workflows/projects/index.md) |
|
|
36
|
+
| `oat repo ...` | Repository-level workflows such as archive sync and PR-comment analysis. | [Repository Analysis](../workflows/projects/repo-analysis.md) |
|
|
37
37
|
|
|
38
|
-
Notable
|
|
38
|
+
Notable commands introduced in the current CLI surface:
|
|
39
39
|
|
|
40
40
|
- `oat config dump --json` - merged config with source attribution
|
|
41
41
|
- `oat project status --json` - full parsed state for the active tracked project. **Stable contract for skills:** the JSON output is a typed read interface for OAT skills; the field set consumed by migrated skills is locked by `MIGRATED_FIELDS` in `packages/cli/src/commands/project/status.test.ts`. Removing or renaming any of `project.{name, path, phase, phaseStatus, workflowMode, docsUpdated, lastCommit, prStatus, prUrl}` is a breaking change and will fail the contract test.
|
|
@@ -44,6 +44,8 @@ Notable inspection commands introduced in the current CLI surface:
|
|
|
44
44
|
- `oat project status --shell NAME=path ...` - print shell-safe assignments for one or more fields from one status read, e.g. `WORKFLOW_MODE='quick'`. This is the preferred multi-field read API for skills. See [Writing Skills → Reading project state](../contributing/skills.md#reading-project-state) for examples and the `npx`-backed `oat` shim contract.
|
|
45
45
|
- `oat project list --json` - summary state for tracked projects under the configured projects root
|
|
46
46
|
- `oat project complete-state <project-path>` - apply the canonical completed-state mutation to a project's `state.md`; used by `oat-project-complete` during lifecycle closeout
|
|
47
|
+
- `oat project archive [project-path]` - archive a tracked project through the same local move, summary export, and optional S3 upload path used by completion. When omitted, the project path falls back to the active project.
|
|
48
|
+
- `oat repo archive sync [project-name]` - hydrate archived project snapshots from the configured repo-scoped S3 archive into `.oat/projects/archived/`. The old `oat project archive sync` path remains as a deprecated shim.
|
|
47
49
|
- `oat project validate-plan --project-path <path>` - validates `oat_plan_parallel_groups` metadata in `plan.md`; exits non-zero on invalid. See [Implementation Execution](../workflows/projects/implementation-execution.md#validating-plan-metadata).
|
|
48
50
|
- `oat project set-mode` — deprecated no-op. Execution mode is no longer user-selectable; emits a deprecation warning and preserves the `--json` contract.
|
|
49
51
|
|
|
@@ -57,7 +57,7 @@ Archive sync surfaces:
|
|
|
57
57
|
|
|
58
58
|
- Local archive root: `.oat/projects/archived/`
|
|
59
59
|
- Remote archive base: `archive.s3Uri` in `.oat/config.json`
|
|
60
|
-
- Archive sync command: `oat
|
|
60
|
+
- Archive sync command: `oat repo archive sync` or `oat repo archive sync <project-name>`
|
|
61
61
|
- Remote archive snapshot shape: `<archive.s3Uri>/<repo-slug>/projects/YYYYMMDD-<project-name>/`
|
|
62
62
|
- Summary export target: `<repo>/<archive.summaryExportPath>/YYYYMMDD-<project-name>.md` when configured
|
|
63
63
|
- Wrap-up export target: `<repo>/<archive.wrapUpExportPath>/YYYY-MM-DD-wrap-up-<label>.md` when configured; otherwise `oat-wrap-up` falls back to `<repo>/.oat/repo/reference/wrap-ups/`
|
|
@@ -112,7 +112,7 @@ Current schema keys:
|
|
|
112
112
|
| `archive.s3SyncOnComplete` | `boolean` | `false` | When `true`, `oat-project-complete` uploads the archived project to the configured S3 archive after local archive succeeds |
|
|
113
113
|
| `archive.summaryExportPath` | `string` | - | Repo-relative directory where completion exports `summary.md` as a dated snapshot like `20260401-<project-name>.md` for durable tracked reference |
|
|
114
114
|
| `archive.wrapUpExportPath` | `string` | - | Repo-relative directory where `oat-wrap-up` writes dated reports like `20260413-wrap-up-past-week.md`; when unset, the skill falls back to `.oat/repo/reference/wrap-ups/` |
|
|
115
|
-
| `archive.awsProfile` | `string` | - | Optional AWS named profile forwarded as `AWS_PROFILE` to every `aws` invocation in archive flows (`oat-project-complete` S3 sync, `oat
|
|
115
|
+
| `archive.awsProfile` | `string` | - | Optional AWS named profile forwarded as `AWS_PROFILE` to every `aws` invocation in archive flows (`oat-project-complete` S3 sync, `oat repo archive sync`). Overrides ambient shell `AWS_PROFILE` / `AWS_DEFAULT_PROFILE` when set. |
|
|
116
116
|
| `archive.awsRegion` | `string` | - | Optional AWS region forwarded as `AWS_REGION` to every `aws` invocation in archive flows. Overrides ambient shell `AWS_REGION` / `AWS_DEFAULT_REGION` when set. |
|
|
117
117
|
|
|
118
118
|
All `documentation.*` keys are managed via `oat config get/set` and are set automatically by `oat docs init`.
|
|
@@ -166,8 +166,8 @@ Archive sync behavior:
|
|
|
166
166
|
|
|
167
167
|
- `oat-project-complete` always archives locally into `.oat/projects/archived/<project>/`.
|
|
168
168
|
- If `archive.s3SyncOnComplete=true` and `archive.s3Uri` is configured, completion also uploads a dated snapshot such as `<archive.s3Uri>/<repo-slug>/projects/20260401-<project>/`.
|
|
169
|
-
- `oat
|
|
170
|
-
- `oat
|
|
169
|
+
- `oat repo archive sync` syncs all repo archived projects down from S3 into `.oat/projects/archived/`.
|
|
170
|
+
- `oat repo archive sync <project-name>` syncs the latest dated remote snapshot for a single project into `.oat/projects/archived/<project-name>/`.
|
|
171
171
|
- Default archive sync is non-destructive toward unrelated local-only archive data, but it does replace a local project archive when a newer dated remote snapshot is selected for that same project.
|
|
172
172
|
|
|
173
173
|
Typical contents:
|
|
@@ -39,4 +39,4 @@ This sub-section is the deep technical surface for how tracked OAT projects exec
|
|
|
39
39
|
- [State Machine](state-machine.md) - Lifecycle and review status transitions across a project.
|
|
40
40
|
- [Reviews](reviews.md) - How review request/receive loops work inside OAT projects.
|
|
41
41
|
- [PR Flow](pr-flow.md) - Progress and final PR generation expectations.
|
|
42
|
-
- [Repository Analysis](repo-analysis.md) - Repo-wide PR comment collection and triage workflows.
|
|
42
|
+
- [Repository PR Comment Analysis](repo-analysis.md) - Repo-wide PR comment collection and triage workflows.
|
|
@@ -65,7 +65,7 @@ On completion, OAT now treats archive handling as part of the closeout lifecycle
|
|
|
65
65
|
- If `.oat/config.json` sets `archive.awsProfile` and/or `archive.awsRegion`, those values are forwarded to every `aws` invocation triggered by completion (preflight checks + `aws s3 sync`) and override any ambient shell `AWS_PROFILE` / `AWS_DEFAULT_PROFILE` / `AWS_REGION` / `AWS_DEFAULT_REGION` values. The repo's archive-scoped credentials are treated as deliberate intent so users don't have to unset shell env vars before running completion. See [`config-and-local-state.md`](../../cli-utilities/config-and-local-state.md) for the full precedence chain.
|
|
66
66
|
- If `.oat/config.json` sets `archive.summaryExportPath`, completion copies `summary.md` to `<archive.summaryExportPath>/20260401-<project>.md`.
|
|
67
67
|
- Missing or unusable AWS CLI configuration produces warnings during completion instead of blocking closeout.
|
|
68
|
-
- `oat
|
|
68
|
+
- `oat repo archive sync` can later sync all archived projects, or one named archived project, back down from S3; it selects the latest dated remote snapshot and materializes it into the local bare archive tree.
|
|
69
69
|
|
|
70
70
|
### Phase status: `pr_open`
|
|
71
71
|
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
---
|
|
2
|
-
title: Repository Analysis
|
|
3
|
-
description: 'Repository-level analysis commands for collecting and triaging
|
|
2
|
+
title: Repository PR Comment Analysis
|
|
3
|
+
description: 'Repository-level PR comment analysis commands for collecting and triaging review feedback.'
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Repository Analysis (`oat repo`)
|
|
6
|
+
# Repository PR Comment Analysis (`oat repo pr-comments`)
|
|
7
7
|
|
|
8
|
-
The `oat repo` command group provides repository-level analysis
|
|
8
|
+
The `oat repo pr-comments` command group provides repository-level review analysis tools. These commands operate across merged pull requests rather than on individual PRs.
|
|
9
|
+
|
|
10
|
+
This page covers the PR-comment analysis surface only. Other repository-level commands, such as `oat repo archive sync`, are covered in [Lifecycle](lifecycle.md#completion-archive-behavior) and [Configuration](../../cli-utilities/configuration.md#shared-repo-config-you-will-touch-most-often).
|
|
9
11
|
|
|
10
12
|
## Quick Look
|
|
11
13
|
|
|
@@ -100,3 +102,4 @@ Both commands accept dependency injection for testability:
|
|
|
100
102
|
|
|
101
103
|
- Source: `packages/cli/src/commands/repo/pr-comments/`
|
|
102
104
|
- Types: `packages/cli/src/commands/repo/pr-comments/collect/pr-comments.types.ts`
|
|
105
|
+
- Archive sync: [Lifecycle](lifecycle.md#completion-archive-behavior) and [Configuration](../../cli-utilities/configuration.md#shared-repo-config-you-will-touch-most-often)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: oat-agent-instructions-apply
|
|
3
|
-
version: 1.6.
|
|
3
|
+
version: 1.6.2
|
|
4
4
|
description: Run when you have an agent instructions analysis artifact and want to generate or update instruction files. Creates a branch, generates files from templates, and optionally opens a PR.
|
|
5
5
|
disable-model-invocation: true
|
|
6
6
|
user-invocable: true
|
|
@@ -217,6 +217,7 @@ recommendation so plan review and generation stay aligned to the same pack file.
|
|
|
217
217
|
1. **AGENTS.md first** — the canonical, provider-agnostic file
|
|
218
218
|
2. **CLAUDE.md** — if claude provider is active, ensure `@AGENTS.md` import exists
|
|
219
219
|
3. **Glob-scoped rules** — author once in canonical format at `.agents/rules/{name}.md` with YAML frontmatter (`description`, `globs`, `activation`)
|
|
220
|
+
- `activation` MUST be one of `always`, `glob`, `agent-requested`, `manual` — any other value (e.g. `auto`) is rejected by `oat sync`. Use `glob` (with `globs`) for file-targeted rules; see `frontmatter/canonical-rule.md` for the full activation matrix.
|
|
220
221
|
- Provider-specific rule files are generated by `oat sync --scope project`
|
|
221
222
|
- Do not hand-author `.claude/rules/*.md`, `.cursor/rules/*.mdc`, or `.github/instructions/*.instructions.md`
|
|
222
223
|
4. **Copilot shim** — if copilot provider is active, generate `.github/copilot-instructions.md` from `frontmatter/copilot-shim.md` template
|
|
@@ -320,7 +321,7 @@ For each approved recommendation, in the order from Step 2:
|
|
|
320
321
|
- `Claim Corrections` replaces stale claims in updated files
|
|
321
322
|
6. For glob-scoped rules:
|
|
322
323
|
- Write the canonical markdown once to `.agents/rules/{name}.md`
|
|
323
|
-
- Include canonical rule frontmatter (`description`, `globs`, `activation`) instead of provider-specific wrappers
|
|
324
|
+
- Include canonical rule frontmatter (`description`, `globs`, `activation`) instead of provider-specific wrappers. `activation` must be one of `always`, `glob`, `agent-requested`, `manual` (not `auto`); use `glob` with `globs` for file-targeted rules. See `references/instruction-file-templates/frontmatter/canonical-rule.md`.
|
|
324
325
|
- After writing canonical rules, run `oat sync --scope project` to generate provider-specific rule files
|
|
325
326
|
- Verify the generated provider files exist for each active provider instead of maintaining them by hand
|
|
326
327
|
- Verify each generated provider file is trackable with `git check-ignore`; if any generated file is ignored,
|
|
@@ -503,5 +504,6 @@ Apply complete.
|
|
|
503
504
|
- Bundled Cursor-specific format reference: `references/docs/cursor-rules-files.md`
|
|
504
505
|
- Analysis artifact: `.oat/repo/analysis/agent-instructions-*.md`
|
|
505
506
|
- Templates: `references/instruction-file-templates/`
|
|
507
|
+
- Canonical rule frontmatter reference: `references/instruction-file-templates/frontmatter/canonical-rule.md`
|
|
506
508
|
- Apply plan template: `references/apply-plan-template.md`
|
|
507
509
|
- Tracking script: `.oat/scripts/resolve-tracking.sh`
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# Canonical Rule Frontmatter
|
|
2
|
+
|
|
3
|
+
Canonical glob-scoped rules live at `.agents/rules/{name}.md`. This is the **single source you author** — `oat sync --scope project` reads it and generates the provider-specific rule files (`.claude/rules/*.md`, `.cursor/rules/*.mdc`, `.github/instructions/*.instructions.md`). Do not hand-author those provider files.
|
|
4
|
+
|
|
5
|
+
The canonical frontmatter is provider-agnostic and uses three fields: `description`, `globs`, and `activation`.
|
|
6
|
+
|
|
7
|
+
## Frontmatter Fields
|
|
8
|
+
|
|
9
|
+
| Field | Required | Type | Description |
|
|
10
|
+
| ------------- | ----------- | -------- | -------------------------------------------------------------------------------------- |
|
|
11
|
+
| `activation` | **Yes** | enum | One of `always`, `glob`, `agent-requested`, `manual`. See matrix below. |
|
|
12
|
+
| `globs` | Conditional | string[] | Glob patterns the rule targets. **Required when `activation: glob`.** |
|
|
13
|
+
| `description` | Conditional | string | Short purpose. **Required when `activation: agent-requested`**; recommended otherwise. |
|
|
14
|
+
|
|
15
|
+
> The `activation` value is validated. The only accepted values are
|
|
16
|
+
> `always`, `glob`, `agent-requested`, and `manual`. Any other value
|
|
17
|
+
> (e.g. `auto`) is rejected by `oat sync --scope project`.
|
|
18
|
+
|
|
19
|
+
## Activation Matrix
|
|
20
|
+
|
|
21
|
+
| `activation` | When to use | Required companion fields |
|
|
22
|
+
| ----------------- | ---------------------------------------------------------------- | ------------------------- |
|
|
23
|
+
| `glob` | Rule applies to files matching specific patterns | `globs` |
|
|
24
|
+
| `always` | Repo-wide rule that should be in every session | — |
|
|
25
|
+
| `agent-requested` | Agent decides relevance from the description (no file targeting) | `description` |
|
|
26
|
+
| `manual` | Opt-in only — user explicitly invokes the rule | — |
|
|
27
|
+
|
|
28
|
+
Selection rule of thumb: if the recommendation targets file patterns, use `activation: glob` with `globs`. Use `always` only for genuinely repo-wide guidance, `agent-requested` for description-driven rules with no glob, and `manual` for opt-in references.
|
|
29
|
+
|
|
30
|
+
## Examples
|
|
31
|
+
|
|
32
|
+
### Glob-scoped (most common)
|
|
33
|
+
|
|
34
|
+
```yaml
|
|
35
|
+
---
|
|
36
|
+
description: 'Firebase handler trigger/registration conventions'
|
|
37
|
+
activation: glob
|
|
38
|
+
globs:
|
|
39
|
+
- 'src/functions/**/*.ts'
|
|
40
|
+
---
|
|
41
|
+
# {Rule Title}
|
|
42
|
+
|
|
43
|
+
{ Rule body — identical to glob-scoped-rule.md template body }
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### Always-on
|
|
47
|
+
|
|
48
|
+
```yaml
|
|
49
|
+
---
|
|
50
|
+
description: 'Repo-wide security non-negotiables'
|
|
51
|
+
activation: always
|
|
52
|
+
---
|
|
53
|
+
# {Rule Title}
|
|
54
|
+
|
|
55
|
+
{ Rule body }
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### Agent-requested (no globs)
|
|
59
|
+
|
|
60
|
+
```yaml
|
|
61
|
+
---
|
|
62
|
+
description: 'Patreon integration gotchas — apply when touching billing flows'
|
|
63
|
+
activation: agent-requested
|
|
64
|
+
---
|
|
65
|
+
# {Rule Title}
|
|
66
|
+
|
|
67
|
+
{ Rule body }
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### Manual (opt-in)
|
|
71
|
+
|
|
72
|
+
```yaml
|
|
73
|
+
---
|
|
74
|
+
description: 'One-off migration playbook'
|
|
75
|
+
activation: manual
|
|
76
|
+
---
|
|
77
|
+
# {Rule Title}
|
|
78
|
+
|
|
79
|
+
{ Rule body }
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## How It Maps to Providers
|
|
83
|
+
|
|
84
|
+
`oat sync --scope project` translates each canonical `activation` to the equivalent provider frontmatter:
|
|
85
|
+
|
|
86
|
+
| Canonical | Claude (`.claude/rules/*.md`) | Cursor (`.cursor/rules/*.mdc`) | Copilot (`.github/instructions/*`) |
|
|
87
|
+
| ----------------- | ----------------------------- | ------------------------------------ | ---------------------------------- |
|
|
88
|
+
| `glob` | `paths` | `alwaysApply: false` + `globs` | `applyTo` |
|
|
89
|
+
| `always` | no frontmatter (always-on) | `alwaysApply: true` | repo-wide `applyTo` / shim |
|
|
90
|
+
| `agent-requested` | degrades to always-on | `alwaysApply: false` + `description` | degrades to always-on |
|
|
91
|
+
| `manual` | omitted / opt-in | no frontmatter | omitted |
|
|
92
|
+
|
|
93
|
+
See the per-provider frontmatter docs in this directory (`claude-rule.md`, `cursor-rule.md`, `copilot-instruction.md`) for the generated output formats, and `references/docs/rules-files.md` for the full cross-provider deep dive.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: oat-project-complete
|
|
3
|
-
version: 1.4.
|
|
3
|
+
version: 1.4.9
|
|
4
4
|
description: Use when all implementation work is finished and the project is ready to close. Marks the OAT project lifecycle as complete.
|
|
5
5
|
disable-model-invocation: true
|
|
6
6
|
user-invocable: true
|
|
@@ -340,166 +340,30 @@ Anti-pattern: do not "rescue" a dropped artifact by linking to its archived path
|
|
|
340
340
|
|
|
341
341
|
Archive happens after PR description generation (so artifacts are readable at tracked paths) but before commit+push (so the archive deletion is included in the commit).
|
|
342
342
|
|
|
343
|
-
The archive-side effects in this step are CLI-owned.
|
|
344
|
-
|
|
345
|
-
**Anti-pattern (do NOT do this):** Running `git check-ignore` on the
|
|
346
|
-
`.oat/projects/archived` directory itself to decide durability. A common
|
|
347
|
-
gitignore shape for this repo is `.oat/projects/archived/**`, which leaves the
|
|
348
|
-
directory visible in the tree while ignoring every file placed inside. A
|
|
349
|
-
directory-level check reports "not ignored" and produces the inverse of the
|
|
350
|
-
intended decision — archiving in the worktree when the archive must actually
|
|
351
|
-
go to the primary repo. Always probe a representative path **inside** the
|
|
352
|
-
archive directory (the project subpath or a probe filename), matching the CLI
|
|
353
|
-
helper at `packages/cli/src/commands/project/archive/archive-utils.ts`.
|
|
343
|
+
The archive-side effects in this step are CLI-owned. Do not reimplement local archive movement, summary export, S3 sync, AWS credential handling, or worktree durability checks in the skill.
|
|
354
344
|
|
|
355
345
|
```bash
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
PRIMARY_REPO_ARCHIVE=""
|
|
362
|
-
ARCHIVE_CONTENTS_TRACKED="true"
|
|
363
|
-
USE_PRIMARY_REPO_ARCHIVE="false"
|
|
364
|
-
|
|
365
|
-
# Will a newly-archived file at ${ARCHIVE_RELATIVE_PATH} actually be tracked in
|
|
366
|
-
# this checkout? Probe a representative path INSIDE the directory, not the
|
|
367
|
-
# directory itself. A `.oat/projects/archived/**` gitignore pattern leaves the
|
|
368
|
-
# directory visible in the tree but ignores everything placed inside, so a
|
|
369
|
-
# directory-level check reports "tracked" and gives the inverse of the
|
|
370
|
-
# intended answer.
|
|
371
|
-
if git check-ignore --quiet --no-index "$ARCHIVE_RELATIVE_PATH" 2>/dev/null; then
|
|
372
|
-
ARCHIVE_CONTENTS_TRACKED="false"
|
|
373
|
-
fi
|
|
374
|
-
|
|
375
|
-
# Fall back to the primary checkout whenever archive contents are local-only
|
|
376
|
-
# in the current worktree, regardless of whether the archive directory itself
|
|
377
|
-
# happens to exist in the tree.
|
|
378
|
-
if [[ "$ARCHIVE_CONTENTS_TRACKED" == "false" ]] && git rev-parse --is-inside-work-tree >/dev/null 2>&1; then
|
|
379
|
-
GIT_COMMON_DIR=$(git rev-parse --git-common-dir 2>/dev/null || true)
|
|
380
|
-
GIT_DIR=$(git rev-parse --git-dir 2>/dev/null || true)
|
|
381
|
-
if [[ -n "$GIT_COMMON_DIR" && -n "$GIT_DIR" && "$GIT_COMMON_DIR" != "$GIT_DIR" ]]; then
|
|
382
|
-
PRIMARY_REPO_ROOT=$(cd "$(dirname "$GIT_COMMON_DIR")" && pwd)
|
|
383
|
-
PRIMARY_REPO_ARCHIVE="${PRIMARY_REPO_ROOT}/.oat/projects/archived"
|
|
384
|
-
if [[ -d "$(dirname "$PRIMARY_REPO_ARCHIVE")" ]]; then
|
|
385
|
-
USE_PRIMARY_REPO_ARCHIVE="true"
|
|
386
|
-
ARCHIVED_ROOT="$PRIMARY_REPO_ARCHIVE"
|
|
387
|
-
else
|
|
388
|
-
echo "Warning: Running in a worktree with a local-only archive path, but the primary repo archive path is unavailable: $PRIMARY_REPO_ARCHIVE"
|
|
389
|
-
echo "A worktree-local archive may be deleted when the worktree is removed and is not a durable archive."
|
|
390
|
-
echo "Require explicit confirmation before proceeding with local-only archive."
|
|
391
|
-
fi
|
|
392
|
-
fi
|
|
393
|
-
fi
|
|
394
|
-
|
|
395
|
-
if [[ "$USE_PRIMARY_REPO_ARCHIVE" != "true" ]]; then
|
|
396
|
-
ARCHIVED_ROOT=".oat/projects/archived"
|
|
346
|
+
ARCHIVE_OUTPUT=""
|
|
347
|
+
if ! ARCHIVE_OUTPUT=$(oat project archive "$PROJECT_PATH" 2>&1); then
|
|
348
|
+
printf '%s\n' "$ARCHIVE_OUTPUT" >&2
|
|
349
|
+
echo "Error: Project archive failed." >&2
|
|
350
|
+
exit 1
|
|
397
351
|
fi
|
|
398
352
|
|
|
399
|
-
|
|
400
|
-
ARCHIVE_PATH="${ARCHIVED_ROOT}/${PROJECT_NAME}"
|
|
353
|
+
printf '%s\n' "$ARCHIVE_OUTPUT"
|
|
401
354
|
|
|
402
|
-
|
|
403
|
-
|
|
355
|
+
ARCHIVE_PATH=$(printf '%s\n' "$ARCHIVE_OUTPUT" | sed -nE 's/^Archived project `[^`]+` to `(.+)`\.$/\1/p' | tail -1)
|
|
356
|
+
if [[ -z "$ARCHIVE_PATH" ]]; then
|
|
357
|
+
echo "Error: oat project archive did not report the archived path." >&2
|
|
358
|
+
exit 1
|
|
404
359
|
fi
|
|
405
360
|
|
|
406
|
-
mv "$PROJECT_PATH" "$ARCHIVE_PATH"
|
|
407
361
|
PROJECT_PATH="$ARCHIVE_PATH"
|
|
408
|
-
|
|
362
|
+
ARCHIVE_S3_PATH=$(printf '%s\n' "$ARCHIVE_OUTPUT" | sed -nE 's/^S3 archive: (.+)$/\1/p' | tail -1)
|
|
363
|
+
ARCHIVE_S3_CONTEXT=$(printf '%s\n' "$ARCHIVE_OUTPUT" | grep -E '^Archive S3 sync: .*profile=.*region=' | tail -1 || true)
|
|
409
364
|
```
|
|
410
365
|
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
- Always archive locally first. The local archive is the authoritative completion artifact even when remote sync is also configured.
|
|
414
|
-
- If `archive.summaryExportPath` is configured and `summary.md` exists after archive, copy it to `{repoRoot}/{archive.summaryExportPath}/YYYYMMDD-{PROJECT_NAME}.md`.
|
|
415
|
-
- If `archive.s3SyncOnComplete=true` and `archive.s3Uri` is configured, sync the archived project to `{archive.s3Uri}/{repo-slug}/projects/YYYYMMDD-{PROJECT_NAME}/`. The S3 sync excludes process artifacts (`reviews/*`, `pr/*`) — only core deliverables (discovery, spec, design, plan, implementation, summary, state) are uploaded. The CLI enforces this via `S3_ARCHIVE_SYNC_EXCLUDES` in `archive-utils.ts`.
|
|
416
|
-
- If AWS CLI is missing or unusable for that S3 sync, warn and continue. Completion must not fail after the local archive succeeds.
|
|
417
|
-
- If `archive.s3SyncOnComplete` is false or `archive.s3Uri` is unset, skip remote sync without prompting.
|
|
418
|
-
|
|
419
|
-
**AWS credential handling for archive S3 sync (required):**
|
|
420
|
-
|
|
421
|
-
When `archive.s3SyncOnComplete=true` and `archive.s3Uri` is set, the agent MUST honor the repo's archive-scoped AWS credentials instead of falling back to whatever shell profile/region happens to be active. The contract mirrors `buildAwsEnv` in `packages/cli/src/commands/project/archive/archive-utils.ts`.
|
|
422
|
-
|
|
423
|
-
- **Read both keys from OAT config before any AWS CLI call:**
|
|
424
|
-
|
|
425
|
-
```bash
|
|
426
|
-
ARCHIVE_AWS_PROFILE=$(oat config get archive.awsProfile 2>/dev/null || true)
|
|
427
|
-
ARCHIVE_AWS_REGION=$(oat config get archive.awsRegion 2>/dev/null || true)
|
|
428
|
-
```
|
|
429
|
-
|
|
430
|
-
- **Apply them to every `aws` invocation tied to archive sync** — preflight checks (`aws --version`, `aws sts get-caller-identity`), bucket access probes (`aws s3 ls`), and the actual `aws s3 sync`. Do not mix configured values across some calls and ambient values across others.
|
|
431
|
-
- **Configured archive values WIN over ambient shell AWS env vars.** A non-empty `archive.awsProfile` overrides any `AWS_PROFILE` or `AWS_DEFAULT_PROFILE` already exported in the shell. A non-empty `archive.awsRegion` overrides `AWS_REGION` and `AWS_DEFAULT_REGION`. Treat the repo's archive-scoped declaration as deliberate intent — users should not have to unset shell env vars to get correct archive credentials. Empty/unset config values fall through to the AWS CLI's normal resolution chain.
|
|
432
|
-
- **Prefer the OAT CLI when it is available.** If you delegate archive sync to an `oat project archive ...` invocation, the CLI applies the canonical handling for you (config-resolved profile/region clobber the spawned env). Do not pass `--profile` / `--region` flags unless the user asked for a one-off override different from the repo config.
|
|
433
|
-
- **Manual AWS CLI fallback** — when no OAT command wraps the operation and the agent must call `aws` directly, pass the configured profile/region explicitly. Either use flags:
|
|
434
|
-
|
|
435
|
-
```bash
|
|
436
|
-
AWS_FLAGS=()
|
|
437
|
-
if [[ -n "$ARCHIVE_AWS_PROFILE" ]]; then
|
|
438
|
-
AWS_FLAGS+=(--profile "$ARCHIVE_AWS_PROFILE")
|
|
439
|
-
fi
|
|
440
|
-
if [[ -n "$ARCHIVE_AWS_REGION" ]]; then
|
|
441
|
-
AWS_FLAGS+=(--region "$ARCHIVE_AWS_REGION")
|
|
442
|
-
fi
|
|
443
|
-
|
|
444
|
-
aws "${AWS_FLAGS[@]}" sts get-caller-identity
|
|
445
|
-
aws "${AWS_FLAGS[@]}" s3 sync \
|
|
446
|
-
"$ARCHIVE_PATH" \
|
|
447
|
-
"${ARCHIVE_S3_URI%/}/${REPO_SLUG}/projects/${SNAPSHOT_NAME}/" \
|
|
448
|
-
--exclude 'reviews/*' --exclude 'pr/*'
|
|
449
|
-
```
|
|
450
|
-
|
|
451
|
-
…or set the equivalent env vars for the spawned process so the same precedence applies:
|
|
452
|
-
|
|
453
|
-
```bash
|
|
454
|
-
AWS_ENV=()
|
|
455
|
-
[[ -n "$ARCHIVE_AWS_PROFILE" ]] && AWS_ENV+=("AWS_PROFILE=$ARCHIVE_AWS_PROFILE")
|
|
456
|
-
[[ -n "$ARCHIVE_AWS_REGION" ]] && AWS_ENV+=("AWS_REGION=$ARCHIVE_AWS_REGION")
|
|
457
|
-
env "${AWS_ENV[@]}" aws s3 sync ...
|
|
458
|
-
```
|
|
459
|
-
|
|
460
|
-
Both shapes are acceptable; the AWS CLI treats `--profile` / `--region` and `AWS_PROFILE` / `AWS_REGION` env as higher precedence than `AWS_DEFAULT_*`, so the configured values win.
|
|
461
|
-
|
|
462
|
-
- **Report the resolved profile/region in the completion summary** so the user can confirm the right identity ran the sync, e.g. `Archive S3 sync used AWS profile=tkstang-artifact-sync region=us-east-1`. Do not echo raw access keys, session tokens, or any value from `AWS_SECRET_ACCESS_KEY` / `AWS_SESSION_TOKEN`. If `archive.awsProfile` or `archive.awsRegion` is unset, report `<unset; using shell default>` for that field.
|
|
463
|
-
- **AccessDenied troubleshooting** — if `aws s3 sync` returns AccessDenied, confirm before retrying that the spawn actually used `archive.awsProfile` (not the ambient shell profile). A common pitfall is invoking `aws s3 sync` without flags from a shell where `AWS_PROFILE` points at an unrelated identity; rerun with the configured profile/region applied as above.
|
|
464
|
-
|
|
465
|
-
**Worktree durability guard (required):**
|
|
466
|
-
|
|
467
|
-
- If running in a worktree and the primary repo archive path is unavailable, do not silently continue with a local-only archive.
|
|
468
|
-
- Ask the user explicitly: "Primary repo archive path is unavailable, so this archive may be lost when the worktree is deleted. Continue with local-only archive anyway?"
|
|
469
|
-
- If the user declines, skip archiving and continue the completion flow without archive.
|
|
470
|
-
- Resolve the durable repo root from `git rev-parse --git-common-dir` and `git rev-parse --git-dir`, matching the CLI helper in `packages/cli/src/commands/project/archive/archive-utils.ts`. Do not rely on a `main` checkout or default-branch naming.
|
|
471
|
-
- Apply this guard only when `git check-ignore --quiet --no-index "$ARCHIVE_RELATIVE_PATH"` reports that the archive **contents** are local-only in the current checkout. `$ARCHIVE_RELATIVE_PATH` must be a path **inside** the archive directory (the project subpath), never the directory itself — see the anti-pattern note above the bash block.
|
|
472
|
-
|
|
473
|
-
**Git handling after archive:**
|
|
474
|
-
|
|
475
|
-
If the archived directory is gitignored (check with `git check-ignore -q "$ARCHIVE_PATH"`), the move looks like a deletion to git — the original tracked files disappear and the archived copy is local-only. To commit:
|
|
476
|
-
|
|
477
|
-
```bash
|
|
478
|
-
git add -A "$PROJECTS_ROOT/$PROJECT_NAME" 2>/dev/null || true
|
|
479
|
-
```
|
|
480
|
-
|
|
481
|
-
This stages the deletions from the shared directory. The archived copy is preserved locally but not tracked by git.
|
|
482
|
-
|
|
483
|
-
**Worktree archive target (required when available):**
|
|
484
|
-
|
|
485
|
-
If running from a git worktree, prefer the primary repo archive directory whenever a newly-archived file inside `.oat/projects/archived/` would be local-only in the current checkout.
|
|
486
|
-
|
|
487
|
-
Reference path:
|
|
488
|
-
|
|
489
|
-
```bash
|
|
490
|
-
GIT_COMMON_DIR=$(git rev-parse --git-common-dir)
|
|
491
|
-
PRIMARY_REPO_ROOT=$(cd "$(dirname "$GIT_COMMON_DIR")" && pwd)
|
|
492
|
-
PRIMARY_REPO_ARCHIVE="${PRIMARY_REPO_ROOT}/.oat/projects/archived"
|
|
493
|
-
```
|
|
494
|
-
|
|
495
|
-
Guidance:
|
|
496
|
-
|
|
497
|
-
- In a worktree, prefer `PRIMARY_REPO_ARCHIVE` whenever `git check-ignore --quiet --no-index "$ARCHIVE_RELATIVE_PATH"` reports the archive **contents** as ignored — regardless of whether the archive directory itself happens to exist in the tree. Only archive in the current checkout when a hypothetical file at `.oat/projects/archived/<project>/state.md` would actually be tracked here.
|
|
498
|
-
- Do not check `git check-ignore` on `.oat/projects/archived` (the directory itself). A `.oat/projects/archived/**` ignore pattern leaves the directory unignored while ignoring all contents, so a directory-level check reports "tracked" and an agent can mistakenly archive in the worktree.
|
|
499
|
-
- Do not treat the worktree-local archive as durable.
|
|
500
|
-
- If forced to use a local-only archive, warn and require explicit user confirmation.
|
|
501
|
-
- Always write the dated `archive.summaryExportPath` copy into the current checkout (`repoRoot`), even when the project archive itself is written to the primary checkout.
|
|
502
|
-
- Do not hardcode user-specific absolute paths.
|
|
366
|
+
Use `ARCHIVE_S3_CONTEXT` in Step 12 if the command reports profile/region details. If S3 sync ran and only `ARCHIVE_S3_PATH` is available, report the destination and note that credential context was not emitted by the command.
|
|
503
367
|
|
|
504
368
|
### Step 9: Regenerate Dashboard
|
|
505
369
|
|
|
@@ -607,7 +471,7 @@ Show user:
|
|
|
607
471
|
|
|
608
472
|
- "Project **{PROJECT_NAME}** marked as complete."
|
|
609
473
|
- If archived: "Archived location: **{PROJECT_PATH}**"
|
|
610
|
-
- If S3 archive sync ran: include the
|
|
474
|
+
- If S3 archive sync ran: include `ARCHIVE_S3_CONTEXT` when the archive command reported profile/region details. If only `ARCHIVE_S3_PATH` is available, include the S3 destination and note that profile/region context was not reported by the command. Never echo raw credentials (`AWS_SECRET_ACCESS_KEY`, `AWS_SESSION_TOKEN`, etc.).
|
|
611
475
|
- Include commit hash and push result for the bookkeeping changes.
|
|
612
476
|
- If PR was opened: include the PR URL.
|
|
613
477
|
- If `oat_pr_url` is present, show it in the completion summary even when PR creation was skipped because the project already tracked an open PR.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: oat-wrap-up
|
|
3
|
-
version: 1.0.
|
|
3
|
+
version: 1.0.1
|
|
4
4
|
description: Use when preparing a shipping digest or weekly/biweekly wrap-up summarizing OAT projects and merged PRs over a time window. Reads local summary files and GitHub PR metadata; writes a version-controlled markdown report.
|
|
5
5
|
argument-hint: '[--since YYYY-MM-DD] [--until YYYY-MM-DD] [--past-week|--past-2-weeks|--past-month] [--output <path>] [--dry-run]'
|
|
6
6
|
disable-model-invocation: false
|
|
@@ -26,7 +26,7 @@ Don't use when:
|
|
|
26
26
|
|
|
27
27
|
- You need a single specific project's summary — use `oat-project-summary` instead.
|
|
28
28
|
- You want an always-current status view without a fixed window — the wrap-up is window-scoped by design.
|
|
29
|
-
- Archived projects from teammates have not been hydrated locally yet — run `oat
|
|
29
|
+
- Archived projects from teammates have not been hydrated locally yet — run `oat repo archive sync` first so the digest reflects the full team's work. The skill warns if this looks undone but will not auto-run sync.
|
|
30
30
|
|
|
31
31
|
## Arguments
|
|
32
32
|
|
|
@@ -45,7 +45,7 @@ Exactly one time-range specifier is required: either a named range (`--past-week
|
|
|
45
45
|
## Prerequisites
|
|
46
46
|
|
|
47
47
|
- Repository is an OAT project (contains `.oat/`).
|
|
48
|
-
- For cross-teammate visibility: `oat
|
|
48
|
+
- For cross-teammate visibility: `oat repo archive sync` has been run recently so teammates' archived projects are hydrated into `.oat/projects/archived/`. The skill warns if `archive.s3Uri` is configured but the local archive has no `.oat-archive-source.json` metadata files.
|
|
49
49
|
- `gh` CLI authenticated for the current repository (needed for merged-PR fetching via `gh api graphql`).
|
|
50
50
|
|
|
51
51
|
## Mode Assertion
|
|
@@ -57,7 +57,7 @@ Exactly one time-range specifier is required: either a named range (`--past-week
|
|
|
57
57
|
**BLOCKED Activities:**
|
|
58
58
|
|
|
59
59
|
- No modifying OAT project summaries, plan files, or other implementation artifacts.
|
|
60
|
-
- No auto-running `oat
|
|
60
|
+
- No auto-running `oat repo archive sync` — it is a user-gated prerequisite, not a side effect of this skill.
|
|
61
61
|
- No network writes of any kind. The GitHub API is read-only.
|
|
62
62
|
|
|
63
63
|
**ALLOWED Activities:**
|
|
@@ -71,7 +71,7 @@ Exactly one time-range specifier is required: either a named range (`--past-week
|
|
|
71
71
|
If you catch yourself:
|
|
72
72
|
|
|
73
73
|
- About to modify a summary file → STOP, the skill is strictly read-only against summaries.
|
|
74
|
-
- About to auto-run `oat
|
|
74
|
+
- About to auto-run `oat repo archive sync` → STOP, the skill only warns; the user runs sync themselves.
|
|
75
75
|
- About to string-concatenate summary prose verbatim → STOP, the report is a synthesis, not a concatenation.
|
|
76
76
|
- About to skip the prerequisite warning when the local archive is empty and S3 is configured → STOP, emit the warning first.
|
|
77
77
|
|
|
@@ -123,12 +123,12 @@ S3_URI="$(oat config get archive.s3Uri 2>/dev/null || true)"
|
|
|
123
123
|
if [ -n "$S3_URI" ] && [ -d "$ARCHIVE_DIR" ]; then
|
|
124
124
|
if ! find "$ARCHIVE_DIR" -maxdepth 2 -name '.oat-archive-source.json' 2>/dev/null | grep -q . ; then
|
|
125
125
|
printf '⚠️ archive.s3Uri is configured but no archived snapshots are hydrated locally.\n'
|
|
126
|
-
printf ' Run "oat
|
|
126
|
+
printf ' Run "oat repo archive sync" first so teammates archived projects are visible to the wrap-up.\n'
|
|
127
127
|
printf ' (Proceeding with active projects and the version-controlled summaries directory only.)\n'
|
|
128
128
|
fi
|
|
129
129
|
elif [ -n "$S3_URI" ]; then
|
|
130
130
|
printf '⚠️ archive.s3Uri is configured but %s does not exist.\n' "$ARCHIVE_DIR"
|
|
131
|
-
printf ' Run "oat
|
|
131
|
+
printf ' Run "oat repo archive sync" first so archived projects are available.\n'
|
|
132
132
|
printf ' (Proceeding with active projects and the version-controlled summaries directory only.)\n'
|
|
133
133
|
fi
|
|
134
134
|
```
|
|
@@ -362,7 +362,7 @@ so I can review before committing it.
|
|
|
362
362
|
|
|
363
363
|
- Report skeleton: `references/report-template.md`
|
|
364
364
|
- Automation patterns (Claude Code `CronCreate`, Codex host scheduling, plain cron): `references/automation-recipes.md`
|
|
365
|
-
- Prerequisite command: `oat
|
|
365
|
+
- Prerequisite command: `oat repo archive sync` at `packages/cli/src/commands/repo/archive/index.ts`
|
|
366
366
|
- Merged-PR query pattern: `packages/cli/src/commands/repo/pr-comments/collect/collect-comments.ts:198-205`
|
|
367
367
|
- Summary frontmatter schema: `.oat/templates/summary.md`
|
|
368
368
|
- Config key: `archive.wrapUpExportPath` (managed via `oat config set archive.wrapUpExportPath <path>`)
|
|
@@ -377,7 +377,7 @@ so I can review before committing it.
|
|
|
377
377
|
**Report is empty or "no summaries found":**
|
|
378
378
|
|
|
379
379
|
- The window may genuinely have no activity — double-check `SINCE` and `UNTIL`.
|
|
380
|
-
- Check whether teammates' archived projects are hydrated: `ls .oat/projects/archived/` should list directories. If empty and `archive.s3Uri` is configured, run `oat
|
|
380
|
+
- Check whether teammates' archived projects are hydrated: `ls .oat/projects/archived/` should list directories. If empty and `archive.s3Uri` is configured, run `oat repo archive sync` first.
|
|
381
381
|
- Verify that `.oat/projects/*/*/summary.md` and/or `${SUMMARY_EXPORT_PATH}/*.md` contain files whose `oat_last_updated` falls inside the window.
|
|
382
382
|
|
|
383
383
|
**Report is missing PRs that clearly merged in the window:**
|