Commit Graph

90 Commits

Author SHA1 Message Date
gsxdsm
4726af673a FN-7740: fix store-leak and no-retry-on-lock gaps in research/settings-import/agent-export/git/project CLI commands
Close leaked TaskStore/AgentStore handles and retry lock errors across fn research, settings import, agent export, git, and project CLI commands.

- fn research create/list/show/export/cancel/retry now close their resolved store on every exit path except the intentional fire-and-forget --wait-for-completion-less create, which stays open to avoid truncating the background run
- fn settings import retries importSettings through a momentary database-is-locked window and closes the store before every process.exit()
- fn agent export closes both the project TaskStore and the AgentStore it opens on every exit path, including the no-agents-to-export guard
- fn git status/fetch/pull/push and fn agent export switch to a path-only project resolution helper so no cached, never-closed TaskStore is left behind for these read/write-nothing-to-board commands
- fn project list/show compute per-project task counts against an uncached TaskStore that is now closed after every call, and the count read retries a momentary lock instead of silently reporting zero tasks
- Adds dedicated lock-retry regression tests for each touched command plus a changeset documenting the fix

Files changed:
 .changeset/fn-7740-cli-cmd-lock-retry.md           |   7 +
 docs/cli-reference.md                              |  28 +++
 .../__tests__/agent-export-lock-retry.test.ts      | 122 ++++++++++
 .../src/commands/__tests__/git-lock-retry.test.ts  | 129 +++++++++++
 packages/cli/src/commands/__tests__/git.test.ts    |  12 +
 .../commands/__tests__/project-lock-retry.test.ts  | 195 ++++++++++++++++
 .../cli/src/commands/__tests__/project.test.ts     |   8 +
 .../commands/__tests__/research-lock-retry.test.ts | 248 ++++++++++++++++++++
 .../cli/src/commands/__tests__/research.test.ts    |  16 +-
 .../__tests__/settings-import-lock-retry.test.ts   | 170 ++++++++++++++
 .../src/commands/__tests__/settings-import.test.ts |  34 +++
 packages/cli/src/commands/agent-export.ts          |  67 ++++--
 packages/cli/src/commands/git.ts                   |  18 +-
 packages/cli/src/commands/project.ts               |  40 +++-
 packages/cli/src/commands/research.ts              | 254 ++++++++++++++-------
 packages/cli/src/commands/settings-import.ts       |  61 ++++-
 16 files changed, 1284 insertions(+), 125 deletions(-)

Fusion-Task-Id: FN-7740

Fusion-Task-Lineage: 5c572332-b81c-4e16-9748-ce8639f53ff3

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-09 19:58:06 -07:00
gsxdsm
5304af8d0e FN-7739: retry locked store access in backup/mcp/db CLI commands
Audits and hardens `fn backup`, `memory-backup`, `mcp`, and `db vacuum` CLI commands so they retry a locked board database instead of hanging, and reliably close store handles on every exit path.

- Add retryOnLock + closeProjectStore/asLocalProjectContext pattern to backup.ts, memory-backup.ts, mcp.ts, and db.ts (following the FN-7731/FN-7738 pattern)
- Close cached, uncached CWD-fallback, and ad-hoc MCP secrets TaskStores on every exit path (success, error, early-return)
- Retry MCP settings writes and DB VACUUM on lock contention, honoring FUSION_CLI_LOCK_RETRY_MS
- Add lock-retry regression test suites for backup, db, mcp, and memory-backup commands
- Update docs/cli-reference.md with the new retry/lock behavior
- Add changeset (patch) documenting the fix

Files changed:
 .changeset/fn-7739-cli-cmd-lock-retry.md           |   7 +
 docs/cli-reference.md                              |  17 +
 .../commands/__tests__/backup-lock-retry.test.ts   | 202 +++++++++++
 packages/cli/src/commands/__tests__/backup.test.ts |  15 +
 .../src/commands/__tests__/db-lock-retry.test.ts   | 182 ++++++++++
 packages/cli/src/commands/__tests__/db.test.ts     |  15 +
 .../src/commands/__tests__/mcp-lock-retry.test.ts  | 234 ++++++++++++
 packages/cli/src/commands/__tests__/mcp.test.ts    |  14 +
 .../__tests__/memory-backup-lock-retry.test.ts     | 201 +++++++++++
 .../src/commands/__tests__/memory-backup.test.ts   |  15 +
 packages/cli/src/commands/backup.ts                | 252 +++++++++----
 packages/cli/src/commands/db.ts                    |  62 +++-
 packages/cli/src/commands/mcp.ts                   | 391 +++++++++++++++------
 packages/cli/src/commands/memory-backup.ts         | 179 +++++++---
 14 files changed, 1538 insertions(+), 248 deletions(-)

Fusion-Task-Id: FN-7739

Fusion-Task-Lineage: 6dbab086-2bf8-4cd4-950b-04fe39131933

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-09 19:58:06 -07:00
gsxdsm
86bd434c11 FN-7738: retry locked board DB in fn branch-group/pr CLI commands
Audit non-task.ts CLI command families for store-leak / no-retry-on-lock gaps and fix branch-group.ts and pr.ts to match the FN-7731 retryOnLock + closeProjectStore pattern.

- Add retryOnLock handling (honoring FUSION_CLI_LOCK_RETRY_MS) around board DB access in branch-group.ts and pr.ts so a locked store retries and exits promptly instead of hanging.
- Ensure both cached and uncached CWD-fallback project stores are closed on every exit path (success, error, early return) to stop store leaks.
- Extend project-context.ts with shared helpers used by both commands.
- Add regression tests: branch-group-lock-retry.test.ts and pr-lock-retry.test.ts, plus additional coverage in branch-group.test.ts.
- Document the new lock-retry behavior in docs/cli-reference.md.
- Add a patch changeset for @runfusion/fusion describing the user-facing fix.

Files changed:
 .changeset/fn-7738-cli-cmd-lock-retry.md           |   7 +
 docs/cli-reference.md                              |  11 +
 .../__tests__/branch-group-lock-retry.test.ts      | 221 ++++++++
 .../src/commands/__tests__/branch-group.test.ts    |  10 +
 .../src/commands/__tests__/pr-lock-retry.test.ts   | 226 ++++++++
 packages/cli/src/commands/branch-group.ts          | 389 +++++++++-----
 packages/cli/src/commands/pr.ts                    | 575 +++++++++++++--------
 packages/cli/src/project-context.ts                |  26 +
 8 files changed, 1122 insertions(+), 343 deletions(-)

Fusion-Task-Id: FN-7738

Fusion-Task-Lineage: 0bbc8fa2-c4f9-49ed-adb6-7dab57eaee13

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-09 19:58:06 -07:00
gsxdsm
1e79a236b2 FN-7734: generalize lock-retry and store-close pattern across all fn task subcommands
Applies the FN-7731 retryOnLock + closeProjectStore pattern to the ~26 runTask* handlers in task.ts so every 'fn task' subcommand retries a momentarily locked board database and exits promptly instead of hanging or leaking a store handle.

- Generalize retryOnLock/closeProjectStore usage across all runTask* handlers in packages/cli/src/commands/task.ts
- Honor FUSION_CLI_LOCK_RETRY_MS for configurable retry timing
- Close both cached and uncached CWD-fallback stores on exit
- Multi-step flows (create/retry/delete/merge/imports) retry each discrete write independently instead of retrying the whole flow
- Add task-lock-retry.test.ts covering the new retry/close behavior across subcommands
- Update docs/cli-reference.md and task.test.ts for the new behavior
- Add changeset fn-7734-task-cmd-lock-retry-generalized.md (patch)

Files changed:
 .../fn-7734-task-cmd-lock-retry-generalized.md     |    7 +
 docs/cli-reference.md                              |   18 +-
 .../src/commands/__tests__/task-lock-retry.test.ts |  282 ++++
 packages/cli/src/commands/__tests__/task.test.ts   |    9 +-
 packages/cli/src/commands/task.ts                  | 1541 +++++++++++---------
 5 files changed, 1173 insertions(+), 684 deletions(-)

Fusion-Task-Id: FN-7734

Fusion-Task-Lineage: cd5c864b-8a33-4962-803e-bbb353a41085

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-09 19:58:06 -07:00
gsxdsm
7420abe80e FN-7731: add CLI-level lock retry for task show/move commands
Add bounded exponential-backoff retry above the DB layer so `fn task show`/`fn task move` ride out transient SQLite lock contention instead of failing outright or hanging.

- Add packages/cli/src/lock-retry.ts: retries a thunk on SQLite lock errors (via @fusion/core's isSqliteLockError) with exponential backoff capped by a wall-clock deadline (default 15s, override via FUSION_CLI_LOCK_RETRY_MS); non-lock errors propagate immediately; raises LockRetryExhaustedError on deadline exhaustion.
- Wire lock-retry into packages/cli/src/commands/task.ts for the show/move task-store operations, and close the resolved TaskStore for deterministic exit.
- Export isSqliteLockError from packages/core/src/index.ts for CLI reuse.
- Add packages/cli/src/commands/__tests__/task-lock-retry.test.ts covering retry/backoff/deadline/error-passthrough behavior; extend task.test.ts.
- Document the new behavior/env var in docs/cli-reference.md.
- Add changeset (@runfusion/fusion: patch).

Files changed:
 .changeset/fn-7731-task-cmd-lock-retry.md          |   7 +
 docs/cli-reference.md                              |   9 +
 .../src/commands/__tests__/task-lock-retry.test.ts | 430 +++++++++++++++++++++
 packages/cli/src/commands/__tests__/task.test.ts   |  11 +
 packages/cli/src/commands/task.ts                  | 117 +++++-
 packages/cli/src/lock-retry.ts                     | 117 ++++++
 packages/core/src/index.ts                         |   5 +
 7 files changed, 688 insertions(+), 8 deletions(-)

Fusion-Task-Id: FN-7731

Fusion-Task-Lineage: 85543164-10d6-4da9-8c3c-a84cd86827aa

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-09 19:58:05 -07:00
gsxdsm
55dae49b37 FN-7704: fix fn agent stop/start hanging up to 60s due to unclosed store handles
Fix CLI process exit so `fn agent stop`/`fn agent start` no longer hang up to 60s and eventually time out on repeated retries against the same agent.

- Root cause: `resolveProject()` cached an unclosed `TaskStore`, and `createAgentStore()` never closed the `AgentStore` it opened, leaving SQLite handles alive after the command's real work was done.
- Add `resolveProjectPathOnly`/`closeProjectStore` helpers in `project-context.ts` so path-only callers never leak a `TaskStore`.
- Explicitly close `AgentStore` on every exit/return path in `agent.ts`, since `process.exit()` skips pending `finally` blocks.
- Add a bounded fast-fail timeout around the state-store write (default 10s, overridable via `FUSION_AGENT_CMD_TIMEOUT_MS`) so a genuinely stuck operation fails fast with a clear error and non-zero exit instead of hanging.
- Add regression tests covering process-exit/store-closing behavior and update CLI reference docs.
- Add changeset for the patch release.

Files changed:
 .changeset/fn-7704-agent-cmd-hang-fix.md           |   7 +
 docs/cli-reference.md                              |   3 +
 .../commands/__tests__/agent-process-exit.test.ts  | 114 +++++++++++
 packages/cli/src/commands/__tests__/agent.test.ts  | 111 +++++++++-
 packages/cli/src/commands/agent.ts                 | 223 ++++++++++++++++-----
 packages/cli/src/project-context.ts                |  44 ++++
 6 files changed, 444 insertions(+), 58 deletions(-)

Fusion-Task-Id: FN-7704
Fusion-Task-Lineage: 4679d1a0-3ab8-48ce-86b7-5919bba805fb
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-08 23:39:34 -07:00
gsxdsm
34be333a2a FN-7426: add GitLab lifecycle automation
Add GitLab lifecycle automation for comments and source item state changes.

- Add GitLab REST helpers for posting notes and closing or reopening issues and merge requests.
- Register GitLab source-comment, tracking-comment, tracking-state, and source-close services with multi-project lifecycle wiring.
- Add project settings, documentation, tests, and a changeset for GitLab completion comments and auto-close behavior.

Files changed:
 .changeset/fn-7426-gitlab-lifecycle.md             |  7 ++
 docs/cli-reference.md                              |  2 +-
 docs/dashboard-guide.md                            |  3 +-
 docs/settings-reference.md                         |  5 +-
 packages/core/src/settings-schema.ts               |  3 +
 packages/core/src/types.ts                         | 10 +++
 .../src/__tests__/gitlab-issue-comment.test.ts     | 37 +++++++++
 .../__tests__/gitlab-source-issue-close.test.ts    | 29 +++++++
 .../src/__tests__/gitlab-tracking-comments.test.ts | 31 +++++++
 .../src/__tests__/gitlab-tracking-state.test.ts    | 42 ++++++++++
 packages/dashboard/src/__tests__/gitlab.test.ts    | 18 ++++
 .../register-git-github.gitlab-lifecycle.test.ts   | 54 ++++++++++++
 packages/dashboard/src/gitlab-issue-comment.ts     | 62 ++++++++++++++
 packages/dashboard/src/gitlab-lifecycle.ts         | 58 +++++++++++++
 .../dashboard/src/gitlab-source-issue-close.ts     | 45 ++++++++++
 packages/dashboard/src/gitlab-tracking-comments.ts | 77 +++++++++++++++++
 packages/dashboard/src/gitlab-tracking-state.ts    | 97 ++++++++++++++++++++++
 packages/dashboard/src/gitlab.ts                   | 30 +++++++
 .../dashboard/src/routes/register-git-github.ts    | 23 +++++
 19 files changed, 630 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-7426

Fusion-Task-Lineage: a46bd11f-96ef-4291-ab41-829007fa057a

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-02 11:38:34 -07:00
gsxdsm
b8e126eeaf FN-7425: add GitLab tracking metadata to tasks
Persist GitLab tracking metadata and surface it across task APIs and dashboard views.

- add task-store schema, migration, and update helpers for linked GitLab items and stale state
- expose validated GitLab tracking updates through task workflow routes and legacy task payloads
- render GitLab badges, detail-panel metadata, open/unlink actions, styling, i18n strings, and docs
- cover persistence, route validation, task card badges, and task detail interactions with tests
- add a patch changeset for the published Fusion package

Files changed:
 .changeset/fn-7425-gitlab-tracking.md              |   7 ++
 docs/cli-reference.md                              |   2 +-
 docs/dashboard-guide.md                            |   3 +
 packages/core/src/__tests__/db-migrate.test.ts     |  29 +++++
 .../src/__tests__/store-gitlab-tracking.test.ts    | 138 +++++++++++++++++++++
 packages/core/src/db.ts                            |  10 +-
 packages/core/src/gitlab-tracking.ts               |  10 ++
 packages/core/src/index.ts                         |   3 +-
 packages/core/src/store.ts                         | 135 +++++++++++++++++++-
 packages/core/src/types.ts                         |  49 ++++++++
 packages/dashboard/app/api/legacy.ts               |   3 +
 packages/dashboard/app/components/GitLabBadge.tsx  |  33 +++++
 packages/dashboard/app/components/TaskCard.tsx     |   7 +-
 .../dashboard/app/components/TaskCardBadge.tsx     |  15 ++-
 .../dashboard/app/components/TaskDetailModal.css   |  47 +++++--
 .../dashboard/app/components/TaskDetailModal.tsx   | 134 +++++++++++++++++++-
 .../app/components/__tests__/TaskCard.test.tsx     |  49 ++++++++
 .../TaskDetailModal.gitlab-tracking.test.tsx       | 121 ++++++++++++++++++
 .../__tests__/TaskDetailModal.test-helpers.ts      |   1 +
 packages/dashboard/app/styles.css                  |   9 ++
 .../src/__tests__/routes-tasks-ops.test.ts         | 136 ++++++++++++++++++++
 packages/dashboard/src/gitlab.ts                   |  24 +++-
 packages/dashboard/src/routes/register-gitlab.ts   |   1 +
 .../src/routes/register-task-workflow-routes.ts    | 106 +++++++++++++++-
 packages/i18n/locales/en/app.json                  |  31 +++++
 packages/i18n/src/resources.d.ts                   |  31 +++++
 26 files changed, 1106 insertions(+), 28 deletions(-)

Fusion-Task-Id: FN-7425

Fusion-Task-Lineage: 9b5e6005-7284-402e-995c-553be2275eff

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-02 11:38:34 -07:00
gsxdsm
865dec235b FN-7424: add GitLab task imports
Adds GitLab-backed task import flows across the CLI, extension, API, and dashboard.

- Add GitLab client normalization, provenance, duplicate detection, and import routes for project issues, group issues, and merge requests.
- Extend the dashboard import modal with a GitLab provider, resource tabs, previews, imported-state detection, and import actions.
- Add CLI and extension task import commands plus usage event/gating classifications and operator documentation.
- Cover GitLab fetch/import behavior with dashboard, CLI, and gating tests.

Files changed:
 .changeset/fn-7424-gitlab-imports.md               |   7 +
 docs/cli-reference.md                              |  11 +-
 docs/gitlab-parity-inventory.md                    |  10 +-
 docs/task-management.md                            |   6 +-
 packages/cli/skill/fusion/SKILL.md                 |   2 +-
 .../cli/skill/fusion/references/extension-tools.md |  60 ++++
 .../skill/fusion/references/fusion-capabilities.md |   6 +
 packages/cli/src/__tests__/extension.test.ts       |   6 +
 .../__tests__/task-command-gitlab-import.test.ts   |  97 ++++++
 packages/cli/src/bin.ts                            |  25 +-
 packages/cli/src/commands/task.ts                  |  58 ++++
 packages/cli/src/extension.ts                      | 106 +++++++
 packages/core/src/__tests__/usage-events.test.ts   |   2 +
 packages/core/src/types.ts                         |   7 +
 packages/core/src/usage-events.ts                  |   3 +
 packages/dashboard/app/api/legacy.ts               |  52 ++++
 .../dashboard/app/components/GitHubImportModal.css |  41 +++
 .../dashboard/app/components/GitHubImportModal.tsx | 143 ++++++++-
 .../__tests__/GitHubImportModal.test.tsx           |  33 ++
 packages/dashboard/src/__tests__/gitlab.test.ts    |  56 ++++
 .../dashboard/src/__tests__/routes-gitlab.test.ts  |  99 ++++++
 packages/dashboard/src/gitlab.ts                   | 334 +++++++++++++++++++++
 packages/dashboard/src/index.ts                    |  15 +
 packages/dashboard/src/routes.ts                   |   2 +
 packages/dashboard/src/routes/register-gitlab.ts   | 192 ++++++++++++
 .../engine/src/__tests__/agent-action-gate.test.ts |   4 +
 .../gating-classifications-provisioning.test.ts    |  13 +-
 .../src/__tests__/gating-classifications.test.ts   |   6 +
 packages/engine/src/gating-classifications.ts      |   9 +
 29 files changed, 1388 insertions(+), 17 deletions(-)

Fusion-Task-Id: FN-7424
Fusion-Task-Lineage: 8012425c-21d5-4b20-adb7-07d2e5aa1cef
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-02 11:38:34 -07:00
gsxdsm
e85d25e383 FN-7395: fix packaged desktop launch assets
Fix installed desktop launches so they use packaged runtime assets without parsing caller workspaces.

- Resolve normal desktop launches from packaged CLI desktop assets, with explicit override and dev paths.
- Stage desktop runtime assets into the published CLI package and include them in npm files.
- Route desktop --no-auth into the embedded dashboard server and document installed/dev launch behavior.
- Cover invalid JSON caller directories, missing packaged assets, package contents, and CLI routing in tests.

Files changed:
 .changeset/fn-7395-desktop-launcher.md             |   7 ++
 docs/cli-reference.md                              |  12 +-
 packages/cli/package.json                          |   1 +
 packages/cli/src/__tests__/bin.test.ts             |  19 +++
 packages/cli/src/__tests__/package-config.test.ts  |  11 ++
 packages/cli/src/bin.ts                            |  10 +-
 .../cli/src/commands/__tests__/desktop.test.ts     | 132 ++++++++++++++++++---
 packages/cli/src/commands/desktop.ts               |  85 ++++++++-----
 packages/cli/tsup.config.ts                        |  60 ++++++++++
 9 files changed, 285 insertions(+), 52 deletions(-)

Fusion-Task-Id: FN-7395

Fusion-Task-Lineage: e7a8d065-0d41-4fa3-9cea-1cfb5b466d16

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-01 15:39:34 -07:00
gsxdsm
c93f2d4da0 FN-7346: fix TUI settings arrow editing
Fix Settings keyboard handling so arrow keys edit selected enum values in the terminal dashboard.

- Keep Tab as the Settings pane switcher so arrow keys remain scoped to the active pane.
- Route detail-pane left/right arrows and h/l keys through enum setting cycling and remote provider activation.
- Add terminal dashboard coverage for list navigation and enum cycling, plus CLI docs and release note coverage.

Files changed:
 .changeset/fn-7346-tui-settings-arrows.md          |   7 ++
 docs/cli-reference.md                              |   5 +
 .../commands/dashboard-tui/__tests__/app.test.tsx  | 121 ++++++++++++++++++++-
 packages/cli/src/commands/dashboard-tui/app.tsx    | 119 ++++++++++----------
 4 files changed, 186 insertions(+), 66 deletions(-)

Fusion-Task-Id: FN-7346

Fusion-Task-Lineage: c67861a7-7bb3-408d-926c-e85a44fe2dec

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-01 07:33:56 -07:00
gsxdsm
f01e5c9651 FN-7247: document current workflow behavior
Refresh workflow documentation to match the latest runtime, dashboard, and agent tool behavior.

- Add a current workflow behavior inventory covering built-ins, fail-closed runtime semantics, optional gates, settings, tools, routing, and create forwarding.
- Clarify dashboard All workflows aggregation, workflow badges, and workflow-aware task creation behavior.
- Expand editor, agent, CLI, and settings docs for governed workflow authoring, values, trait inspection, and selection boundaries.
- Add docs drift tests requiring workflow docs index coverage and current behavior markers.

Files changed:
 docs/agents.md                                     |  5 +-
 docs/cli-reference.md                              | 11 ++-
 docs/dashboard-guide.md                            | 10 ++-
 docs/settings-reference.md                         |  5 ++
 docs/workflow-editor.md                            | 15 +++-
 docs/workflow-steps.md                             | 48 ++++++++---
 .../cli/src/__tests__/docs-readme-index.test.ts    |  4 +
 .../src/__tests__/workflow-docs-current.test.ts    | 95 ++++++++++++++++++++++
 8 files changed, 172 insertions(+), 21 deletions(-)

Fusion-Task-Id: FN-7247
Fusion-Task-Lineage: 72bf0c89-80a3-440c-b6aa-1aea315279f5
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-29 19:46:23 -07:00
gsxdsm
42226edde1 FN-7245: expose workflow authoring tools to agents
Expose workflow authoring and selection tools through agent-visible extension surfaces.

- Register workflow list/get/create/update/delete/settings/select and trait-list tools in the published pi extension.
- Export shared workflow tool schemas/factories and include workflow settings in centralized authoring tool sets.
- Update action-gate classifications, permission examples, docs, tests, and the changeset for the new agent workflow surface.

Files changed:
 .changeset/FN-7245-workflow-tools.md               |   7 +
 docs/agents.md                                     |   4 +-
 docs/cli-reference.md                              |  17 ++
 docs/workflow-steps.md                             |   9 +-
 .../src/__tests__/extension-workflow-tools.test.ts | 244 +++++++++++++++++++++
 packages/cli/src/__tests__/extension.test.ts       |   8 +
 packages/cli/src/extension.ts                      | 142 ++++++++++++
 packages/core/src/types.ts                         |   6 +-
 .../dashboard/src/__tests__/chat-manager.test.ts   |   9 +-
 .../planning-document-tools-exposure.test.ts       |  19 +-
 .../engine/src/__tests__/agent-action-gate.test.ts |   8 +
 .../agent-workflow-tools-exposure.test.ts          |  30 ++-
 .../src/__tests__/gating-classifications.test.ts   |  13 +-
 .../src/__tests__/permanent-agent-gating.test.ts   |   4 +-
 packages/engine/src/agent-tools.ts                 |  13 +-
 packages/engine/src/gating-classifications.ts      |   6 +-
 packages/engine/src/index.ts                       |   7 +
 17 files changed, 506 insertions(+), 40 deletions(-)

Fusion-Task-Id: FN-7245

Fusion-Task-Lineage: 82501602-7177-4ee8-a67b-32de35aa73de

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-29 16:35:51 -07:00
gsxdsm
3d26d4e74b FN-7127: standardize task show tool naming
Unify task-show references so planning, triage, docs, and telemetry use fn_task_show consistently.

- Replace legacy fn_task_get guidance and examples with fn_task_show across agent prompts, mission planning, triage, and docs.
- Keep fn_task_get as a deprecated read-only recognition alias for historical or in-flight calls.
- Update tests and changesets to cover the unified tool name and usage telemetry.

Files changed:
 .changeset/FN-7118-shared-task-read-tools.md       |  2 +-
 .changeset/FN-7127-unify-task-show-tool-name.md    |  7 ++++++
 docs/cli-reference.md                              |  2 +-
 docs/missions.md                                   |  2 +-
 .../cli/skill/fusion/references/engine-tools.md    |  2 +-
 packages/core/src/__tests__/usage-events.test.ts   |  1 +
 packages/core/src/agent-prompts.ts                 | 12 +++++-----
 .../__tests__/milestone-slice-interview.test.ts    |  2 +-
 .../src/__tests__/mission-interview.test.ts        |  2 +-
 .../src/__tests__/planning-board-tools.test.ts     |  6 ++---
 .../dashboard/src/milestone-slice-interview.ts     |  4 ++--
 packages/dashboard/src/mission-interview.ts        |  2 +-
 packages/dashboard/src/planning-board-tools.ts     | 10 +++++---
 packages/dashboard/src/planning.ts                 |  2 +-
 .../src/__tests__/agent-task-read-tools.test.ts    | 28 +++++++++++++++-------
 packages/engine/src/__tests__/triage.test.ts       |  6 ++---
 packages/engine/src/agent-tools.ts                 |  5 +++-
 packages/engine/src/gating-classifications.ts      |  8 +++++--
 packages/engine/src/triage.ts                      | 12 ++++++----
 19 files changed, 74 insertions(+), 41 deletions(-)

Fusion-Task-Id: FN-7127

Fusion-Task-Lineage: adf5a127-2741-4c88-97b3-aab239ab3960

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-27 12:25:53 -07:00
gsxdsm
9e2fb5d62c FN-7102: count active triage planners in project health
Align project health in-flight readouts with live agent slot holders.\n\n- Count non-paused triage planning tasks alongside in-progress executors for dashboard health and CLI project displays.\n- Keep persisted projectHealth.inFlightAgentCount as bookkeeping while deriving user-facing counts from live task state.\n- Cover CLI and dashboard health routes for paused, inactive, and per-project triage planner cases.\n- Document the live count behavior and add a patch changeset.\n\nFiles changed:\n .changeset/fn-7102-health-triage-inflight.md       |  7 +++\n docs/cli-reference.md                              |  2 +\n docs/multi-project.md                              |  4 +-\n .../cli/src/commands/__tests__/project.test.ts     | 59 +++++++++++++++---\n packages/cli/src/commands/project.ts               | 35 +++++++----\n packages/cli/src/project-resolver.ts               | 17 ++++--\n packages/core/src/types.ts                         |  4 +-\n .../dashboard/src/__tests__/project-routes.test.ts | 71 ++++++++++++++++++----\n .../src/routes/register-project-routes.ts          |  9 ++-\n 9 files changed, 163 insertions(+), 45 deletions(-)

Fusion-Task-Id: FN-7102

Fusion-Task-Lineage: ebcba74c-238d-4ca7-aa77-df0d329c0ea9

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-27 09:28:30 -07:00
gsxdsm
8b22dd2ffe FN-7090: link imported GitHub issues as tracked tasks
Link GitHub issue imports to existing source issues when tracking defaults are enabled.

- Resolve project/global GitHub tracking defaults before CLI, extension, and dashboard issue imports.
- Mark imported issue tasks as tracking-enabled so the post-create hook adopts the source issue instead of creating duplicates.
- Cover tracked and untracked import behavior across CLI tools, task commands, and dashboard GitHub routes.
- Document the import tracking behavior and add a minor changeset for the published CLI.

Files changed:
 .changeset/fn-7090-import-github-tracked.md        |   7 ++
 docs/cli-reference.md                              |   2 +
 docs/settings-reference.md                         |   2 +-
 .../__tests__/extension-github-tracking.test.ts    |  63 +++++++++++
 packages/cli/src/__tests__/extension.test.ts       | 125 ++++++++++++++++++++-
 .../task-command-github-import-tracking.test.ts    | 119 ++++++++++++++++++++
 packages/cli/src/commands/__tests__/task.test.ts   |  64 ++++++++++-
 packages/cli/src/commands/task.ts                  |  30 ++++-
 packages/cli/src/extension.ts                      |  27 +++++
 .../dashboard/src/__tests__/routes-github.test.ts  |  74 ++++++++++++
 .../dashboard/src/routes/register-git-github.ts    |  21 +++-
 11 files changed, 524 insertions(+), 10 deletions(-)

Fusion-Task-Id: FN-7090
Fusion-Task-Lineage: 1e5510c3-7a98-4ff2-a109-e465ff58b9c2
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-27 09:28:29 -07:00
gsxdsm
3bfdb16650 FN-7033: document MCP operator workflows
Add a canonical MCP guide with operator workflows and contract coverage.

- Add docs/mcp.md covering MCP settings resolution, transports, secret references, validation, dashboard management, CLI commands, import/export, and AI lane forwarding.
- Link the MCP guide from the docs index, CLI reference, settings reference, secrets docs, and dashboard guide.
- Add a documentation contract test that checks required guide sections and source-aligned MCP surfaces.

Files changed:
 docs/README.md                                     |   1 +
 docs/cli-reference.md                              |   2 +-
 docs/dashboard-guide.md                            |   2 +-
 docs/mcp.md                                        | 221 +++++++++++++++++++++
 docs/secrets.md                                    |   2 +-
 docs/settings-reference.md                         |   2 +
 .../src/__tests__/mcp-documentation.test.ts        |  65 ++++++
 7 files changed, 292 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-7033

Fusion-Task-Lineage: 530abc69-0247-49ee-9487-54d8e2a1b988
2026-06-26 02:52:51 -07:00
gsxdsm
429143ecf0 FN-7024: add MCP server management CLI
Add CLI support for managing MCP server configuration without exposing secret values.

- Add fn mcp list/add/edit/remove/enable/disable/import/export/validate subcommands.
- Store MCP env and header values as Fusion secret references, including Claude Desktop import conversion.
- Document MCP CLI usage and add command coverage for scoped configuration, import, export, and validation.
- Add a minor changeset for the published CLI feature.

Files changed:
 .changeset/fn-7024-mcp-cli.md                   |   7 +
 docs/cli-reference.md                           |  49 +++
 packages/cli/src/bin.ts                         | 124 +++++++
 packages/cli/src/commands/__tests__/mcp.test.ts | 182 ++++++++++
 packages/cli/src/commands/mcp.ts                | 455 ++++++++++++++++++++++++
 5 files changed, 817 insertions(+)

Fusion-Task-Id: FN-7024

Fusion-Task-Lineage: e3d98bfa-b883-4b9e-86d5-f0416808d6f2
2026-06-25 23:34:07 -07:00
gsxdsm
a986a45e48 FN-6852: document desktop engine startup
Clarify that desktop CLI launches with the local AI engine by default.\n\n- Document fn desktop as engine-on by default, matching dashboard startup behavior.\n- Clarify --paused keeps the engine process running with automation disabled.\n- Note that desktop has no --no-engine mode and update desktop README launch steps.\n\nFiles changed:\n docs/cli-reference.md      | 12 ++++++++++--\n packages/desktop/README.md | 15 +++++++++++----\n 2 files changed, 21 insertions(+), 6 deletions(-)

Fusion-Task-Id: FN-6852

Fusion-Task-Lineage: 3ae2ea10-ede1-4cc5-a3b5-71f692b2a9ac
2026-06-21 13:25:41 -07:00
gsxdsm
7ef381762a feat: start engines by default 2026-06-20 23:57:37 -07:00
gsxdsm
a84a8e1793 FN-6570: guard task list formatting fallback
Prevent fn_task_list surfaces from crashing when the runtime core namespace lacks the clamp export.

- Add a shared defensive task-list formatter with a bounded fallback clamp.
- Route CLI, dashboard planning-board, and engine triage fn_task_list output through the formatter.
- Cover missing, throwing, and non-string clamp behavior in core and CLI tests.
- Document the resilient task-list formatting behavior and add a patch changeset.

Files changed:
 .changeset/fn-6570-task-list-resolve-fix.md        |  5 ++
 docs/cli-reference.md                              |  2 +-
 packages/cli/src/__tests__/extension.test.ts       | 57 +++++++++++++++++++++-
 packages/cli/src/extension.ts                      |  8 ++-
 .../core/src/__tests__/task-list-format.test.ts    | 49 ++++++++++++++++++-
 packages/core/src/index.ts                         |  2 +-
 packages/core/src/task-list-format.ts              | 35 +++++++++++++
 packages/dashboard/src/planning-board-tools.ts     |  8 ++-
 packages/engine/src/triage.ts                      |  8 ++-
 9 files changed, 164 insertions(+), 10 deletions(-)

Fusion-Task-Id: FN-6570

Fusion-Task-Lineage: 455f38a8-5e4f-4643-a3ce-088ef0c92b01
2026-06-17 06:14:10 -07:00
gsxdsm
601a85b7c9 FN-6474: clarify plugin tarball install docs
Clarifies packaged external plugin proof-point docs so tarballs are extracted before installation.

- Document that fn plugin install accepts built plugin directories or installed package names, not raw .tgz archives.
- Update external plugin proof-point and authoring guidance to extract pnpm pack output and install ./package.
- Add a static regression test guarding the runbook and authoring guide against raw tarball install instructions.

Files changed:
 docs/cli-reference.md                              |  1 +
 docs/plugins/external-authoring.md                 |  2 +-
 docs/plugins/external-proof-point-runbook.md       | 10 +++++-
 .../external-proof-point-runbook-install.test.ts   | 40 ++++++++++++++++++++++
 4 files changed, 51 insertions(+), 2 deletions(-)

Fusion-Task-Id: FN-6474

Fusion-Task-Lineage: 744d43ff-ed98-43a1-9cb9-e25f96225ab7
2026-06-16 15:08:24 -07:00
gsxdsm
66591ec11c FN-6333: add legacy auto-merge cleanup surfaces
Expose operator controls for auditing and clearing legacy auto-merge stamps.

- Add CLI dry-run, apply, and JSON modes for legacy auto-merge stamp cleanup.
- Add dashboard maintenance endpoints and a Settings → Merge cleanup panel.
- Document the cleanup workflow and cover CLI, route, and UI behavior with tests.

Files changed:
 .changeset/fn-6333-legacy-automerge-cleanup.md     |   5 +
 docs/cli-reference.md                              |   4 +
 docs/dashboard-guide.md                            |   6 ++
 docs/settings-reference.md                         |   2 +-
 packages/cli/src/__tests__/bin.test.ts             |  10 ++
 .../cli/src/__tests__/pr-automerge-cleanup.test.ts | 107 ++++++++++++++++++++
 packages/cli/src/bin.ts                            |  14 ++-
 packages/cli/src/commands/pr.ts                    |  41 ++++++++
 .../components/settings/sections/MergeSection.tsx  | 109 ++++++++++++++++++++
 .../MergeSection.legacy-automerge-cleanup.test.tsx | 110 +++++++++++++++++++++
 .../legacy-automerge-stamps-routes.test.ts         |  76 ++++++++++++++
 packages/dashboard/src/routes.ts                   |  36 +++++++
 12 files changed, 517 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-6333
Fusion-Task-Lineage: 55a3fa22-e0ba-4996-bfce-cad31c71177d
2026-06-13 06:12:09 -07:00
gsxdsm
508551c593 FN-6299: allow archiving tasks from any column
Allow task archiving from every live board column while preserving a safe restore target.

- Record the pre-archive column and restore archived tasks to that column, downgrading active execution columns to todo.
- Expose archive actions and CLI/tooling documentation for all non-archived tasks.
- Expand store, dashboard, and route tests for archive/unarchive behavior across columns.
- Quarantine the flaky core db test observed during verification and add the published package changeset.

Files changed:
 .changeset/fn-6299-archive-any-column.md           |  5 ++
 docs/cli-reference.md                              |  4 ++
 docs/task-management.md                            |  9 +--
 .../cli/skill/fusion/references/extension-tools.md |  6 +-
 .../skill/fusion/references/fusion-capabilities.md |  4 +-
 packages/cli/src/bin.ts                            |  2 +-
 packages/cli/src/extension.ts                      | 18 ++---
 .../src/__tests__/store-archive-search.test.ts     | 76 +++++++++++++++++-----
 packages/core/src/store.ts                         | 61 ++++++++++++-----
 packages/core/src/types.ts                         |  4 ++
 packages/core/vitest.config.ts                     |  1 +
 packages/dashboard/app/components/TaskCard.tsx     |  2 +-
 .../dashboard/app/components/TaskDetailModal.tsx   |  2 +-
 .../app/components/__tests__/TaskCard.test.tsx     | 35 +++++++++-
 ...etailModal.responsive-and-dependencies.test.tsx | 26 ++++++++
 .../src/__tests__/routes-tasks-ops.test.ts         |  8 +--
 .../src/routes/register-task-workflow-routes.ts    |  9 +--
 scripts/lib/test-quarantine.json                   |  5 ++
 18 files changed, 215 insertions(+), 62 deletions(-)

Fusion-Task-Id: FN-6299

Fusion-Task-Lineage: fd5b5c12-35b8-4843-ab4e-14608d1ea395
2026-06-12 21:50:49 -07:00
gsxdsm
db971a91ea fix(FN-1455): initialize git during project registration
Fusion-Task-Id: FN-1455
2026-06-06 00:38:28 -07:00
gsxdsm
26bc80a0ad FN-5958: add mission goal linking to create and update flows
Expand mission goal-link management across the REST API, CLI, and pi extension.

- accept optional goalIds during mission create and patch requests, and enforce archived-goal rejection while keeping unlink permissive
- add repeatable --goal support to fn mission create and reuse goal validation for CLI linking
- expose archived-goal errors in pi-extension mission goal tools and document the new behavior

Files changed:
 .changeset/FN-5958-mission-goal-links.md           |  10 +
 docs/cli-reference.md                              |   8 +-
 docs/missions.md                                   |  15 +-
 packages/cli/src/__tests__/bin.test.ts             |  34 ++++
 packages/cli/src/__tests__/extension-mission-goal-tools.test.ts |  36 ++++
 packages/cli/src/bin.ts                            |  24 ++-
 packages/cli/src/commands/mission.ts               |  29 ++-
 packages/cli/src/extension.ts                      |   7 +
 packages/dashboard/src/__tests__/mission-goal-links-routes.test.ts | 201 ++++++++++++++++++++-
 packages/dashboard/src/mission-routes.ts           |  66 +++++--
 10 files changed, 390 insertions(+), 40 deletions(-)

Fusion-Task-Id: FN-5958
Fusion-Task-Lineage: cf9d6013-5484-439d-b66d-44cac843c6ef
2026-06-03 22:31:23 -07:00
gsxdsm
e703bdd608 feat(i18n): add Korean locale + localized READMEs with language switcher
- ko added to SUPPORTED_LOCALES and every enumeration site (config,
  settings enum, help text, tests); Korean catalogs authored for all
  current keys; CLI bundles regenerated for 6 locales; 한국어 endonym
- README translated into zh-CN, zh-TW, fr, es, ko; every README carries
  a language-switcher line and the localized ones note that English is
  canonical

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 17:33:16 -07:00
gsxdsm
ece6cc6635 feat(i18n): add machine-drafted translations and contributor docs (U8)
Fill zh-CN, zh-TW, fr, and es catalogs for the migrated keys. zh-CN and zh-TW
are independently localized (Simplified vs Traditional script + Taiwan
vocabulary, e.g. 项目/任务 vs 專案/工作), not script-converted. Translations are
machine-drafted and flagged for human review in locales/TRANSLATION_STATUS.md.

Add docs/i18n-contributing.md (translate / add-a-language / --lang usage) and
cross-link it from contributing.md and cli-reference.md. i18n:status reports
100% for all four locales across the migrated key set.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 08:33:34 -07:00
gsxdsm
93e8bd9940 FN-5899: add mission-goal linking commands and tools
Add mission↔goal linkage support across the API, CLI, and pi-extension surfaces.

- add mission goal list/link/unlink REST endpoints and dashboard route coverage
- add `fn mission goals`, `fn mission link-goal`, and `fn mission unlink-goal` CLI commands with tests
- add `fn_mission_list_goals`, `fn_mission_link_goal`, and `fn_mission_unlink_goal` extension tools plus skill/docs updates
- add a changeset for the published CLI package release

Files changed:
 .changeset/FN-5899-mission-goal-tooling.md         |   5 +
 docs/cli-reference.md                              |  11 +-
 docs/missions.md                                   |  27 ++++
 packages/cli/skill/fusion/SKILL.md                 |   2 +-
 packages/cli/skill/fusion/references/extension-tools.md |  26 ++++
 packages/cli/skill/fusion/references/fusion-capabilities.md |   3 +
 packages/cli/src/__tests__/bin.test.ts             |  21 +++
 packages/cli/src/__tests__/extension-mission-goal-tools.test.ts | 140 +++++++++++++++++
 packages/cli/src/bin.ts                            |  32 +++-
 packages/cli/src/commands/__tests__/mission.test.ts     |  99 +++++++++++-
 packages/cli/src/commands/mission.ts               | 102 +++++++++++++-
 packages/cli/src/extension.ts                      | 170 +++++++++++++++++++++
 packages/dashboard/src/__tests__/mission-goal-links-routes.test.ts | 151 ++++++++++++++++++
 packages/dashboard/src/mission-routes.ts           | 153 ++++++++++++++++++-
 14 files changed, 930 insertions(+), 12 deletions(-)

Fusion-Task-Id: FN-5899

Fusion-Task-Lineage: c63b0f4b-c77e-4229-ade4-537a4dda0f5f
2026-06-02 14:47:51 -07:00
gsxdsm
0a418e6875 FN-5844: add plugin dev loop and external authoring docs
Add a local plugin development loop plus publishable external plugin guidance.

- add `fn plugin dev` routing and implementation with supervised build, install, and hot-reload behavior
- export plugin loader/store helpers and add CLI tests for dev flow, pack shape validation, and scaffold docs coverage
- document external plugin authoring, update CLI/plugin authoring docs, and add a patch changeset for `@runfusion/fusion`

Files changed:
 .changeset/fn-5844-external-plugin-authoring.md    |   5 +
 docs/PLUGIN_AUTHORING.md                           |  10 +-
 docs/cli-reference.md                              |   3 +-
 docs/plugins/external-authoring.md                 | 114 +++++++++++
 packages/cli/src/__tests__/bin.test.ts             |  16 +-
 packages/cli/src/__tests__/plugin-dev.test.ts      | 138 ++++++++++++++
 .../cli/src/__tests__/plugin-pack-shape.test.ts    |  94 +++++++++
 packages/cli/src/__tests__/plugin-scaffold.test.ts |   3 +
 packages/cli/src/bin.ts                            |  16 +-
 packages/cli/src/commands/plugin-dev.ts            | 212 +++++++++++++++++++++
 packages/cli/src/commands/plugin-scaffold.ts       |   6 +-
 packages/cli/src/commands/plugin.ts                |   6 +-
 12 files changed, 613 insertions(+), 10 deletions(-)

Fusion-Task-Id: FN-5844
Fusion-Task-Lineage: 80afa0a0-225c-486d-901a-909d14e7b056
2026-06-01 19:40:28 -07:00
gsxdsm
d4db0b0b00 FN-5847: honor onboarding completion marker in auto-launch
CLI onboarding auto-launch now skips once the persisted completion marker is present.

- Load `cliOnboardingCompletedAt` from global settings before launching onboarding when the central DB is missing.
- Preserve existing skip precedence for non-TTY, command, flag, environment, and central DB guards.
- Add unit and backcompat coverage for completion-marker and skipped-central-DB scenarios.
- Document the updated auto-launch behavior and add a patch changeset.

Files changed:
 .changeset/fn-5847-onboard-autolaunch-marker.md    |  5 ++
 docs/cli-reference.md                              | 12 +--
 .../onboard-autolaunch-backcompat-e2e.test.ts      |  7 ++
 .../onboard-autolaunch-backcompat.test.ts          |  8 ++
 .../__tests__/onboard-autolaunch-bypass.test.ts    |  7 ++
 .../commands/__tests__/onboard-autolaunch.test.ts  | 93 ++++++++++++++++++++++
 packages/cli/src/commands/onboard-autolaunch.ts    | 46 ++++++++++-
 7 files changed, 171 insertions(+), 7 deletions(-)

Fusion-Task-Id: FN-5847

Fusion-Task-Lineage: db3e474e-e4b8-4299-8087-07b6cd1f4518
2026-06-01 18:52:28 -07:00
gsxdsm
c676cbe12f FN-5813: update fn onboard help and CLI docs
Align onboarding HELP text and CLI reference with current fn onboarding behavior.

- Document onboarding auto-launch conditions around missing central DB and interactive command flow.
- Add and clarify onboarding escape hatches: --skip-onboarding and FUSION_SKIP_ONBOARDING.
- Add an onboard docs parity test to keep HELP and docs aligned for key onboarding terms.
- Add a patch changeset for @runfusion/fusion describing the documentation/help update.

Files changed:
 .changeset/fn-5813-onboard-docs.md                 |  5 ++++
 docs/cli-reference.md                              | 21 +++++++++-----
 packages/cli/src/bin.ts                            |  4 ++-
 packages/cli/src/commands/__tests__/onboard-docs.test.ts    | 33 ++++++++++++++++++++++
 4 files changed, 55 insertions(+), 8 deletions(-)

Fusion-Task-Id: FN-5813

Fusion-Task-Lineage: 14a74ad9-5f09-471a-878d-aa120a28ef41
2026-06-01 17:15:11 -07:00
gsxdsm
245129e24c FN-5812: add onboard autolaunch backcompat guard coverage
Protect onboarding autolaunch behavior so legacy projects and agent-run commands are not blocked.

- add end-to-end CLI test coverage for onboarding autolaunch backcompat guard behavior
- document the onboarding autolaunch compatibility behavior in the CLI reference
- add a patch changeset for @runfusion/fusion release tracking

Files changed:
 .changeset/fn-5812-onboard-backcompat-guard.md     |   5 +
 docs/cli-reference.md                              |   6 +
 packages/cli/src/commands/__tests__/onboard-autolaunch-backcompat-e2e.test.ts      | 161 +++++++++++++++++++++
 3 files changed, 172 insertions(+)

Fusion-Task-Id: FN-5812

Fusion-Task-Lineage: d735ef0e-1abc-4c22-bd11-07c2de69ace1
2026-06-01 16:55:56 -07:00
gsxdsm
9cbb54906f FN-5843: scaffold standalone external-author plugins with reference template
Add a standalone external-author plugin scaffold flow and reference plugin output for fn plugin new.

- add standalone scaffold mode to plugin generator with external-author defaults
- generate reference plugin files and metadata tailored for out-of-tree/plugin-author usage
- update CLI wiring and command behavior for the new scaffold path
- expand CLI and scaffold tests to cover standalone generation behavior
- document the updated plugin scaffolding flow in CLI reference docs

Files changed:
 docs/cli-reference.md                              |   3 +-
 packages/cli/src/__tests__/bin.test.ts             |  12 +-
 packages/cli/src/__tests__/plugin-scaffold.test.ts | 114 ++++++---
 packages/cli/src/bin.ts                            |  18 +-
 packages/cli/src/commands/plugin-scaffold.ts       | 269 +++++++++++++++++++--
 5 files changed, 356 insertions(+), 60 deletions(-)

Fusion-Task-Id: FN-5843

Fusion-Task-Lineage: 4383e9ed-0b12-451e-a946-2d002f7e8faf
2026-06-01 16:20:52 -07:00
gsxdsm
40b491958f FN-5806: make onboarding steps individually skippable
Allow each fn onboard stage to be skipped without exiting the overall onboarding flow.

- add a reusable skippable-step helper that prompts before each onboarding section
- gate central DB setup, provider setup, project init, core settings, and next-steps output behind per-step skip prompts
- preserve onboarding completion persistence while keeping cancellation semantics intact
- expand onboarding command tests for full skip, selective skip, and cancellation coverage
- document per-step skip behavior in the CLI reference
- add a patch changeset for @runfusion/fusion

Files changed:
 .changeset/fn-5806-onboard-step-skip.md            |   5 +
 docs/cli-reference.md                              |   3 +-
 packages/cli/src/commands/__tests__/onboard.test.ts     |  72 ++++++++++++-
 packages/cli/src/commands/onboard.ts               | 112 ++++++++++++---------
 4 files changed, 141 insertions(+), 51 deletions(-)

Fusion-Task-Id: FN-5806

Fusion-Task-Lineage: d122d67a-2a13-4b2f-a1aa-459dc548d370
2026-06-01 13:20:55 -07:00
gsxdsm
e854d33375 FN-5805: add fn onboard command with sequential runOnboard flow
Add a new interactive onboarding CLI flow that guides first-time setup end to end.

- add new `fn onboard` command wiring in CLI entrypoint and usage help
- implement `runOnboard()` with sequential prompts for central DB, provider auth, init, test mode, and project maxConcurrent
- persist `cliOnboardingCompletedAt` marker in global settings with `--force` rerun support
- add onboarding command tests and global settings regression coverage
- document `fn onboard` usage and options in CLI reference
- add a minor changeset for published `@runfusion/fusion`

Files changed:
 .changeset/fn-5805-onboard-command.md              |   5 +
 docs/cli-reference.md                              |  20 ++
 packages/cli/src/bin.ts                            |  10 +
 packages/cli/src/commands/__tests__/onboard.test.ts| 193 ++++++++++++++++
 packages/cli/src/commands/onboard.ts               | 249 +++++++++++++++++++++
 packages/core/src/__tests__/global-settings.test.ts|  11 +
 packages/core/src/index.ts                         |   2 +-
 packages/core/src/settings-schema.ts               |   1 +
 packages/core/src/types.ts                         |   4 +
 9 files changed, 494 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-5805

Fusion-Task-Lineage: b1bcaf27-9bd7-4569-b685-225a97fa1200
2026-06-01 01:42:19 -07:00
gsxdsm
71e2aec5b7 FN-5663: add goal-citation audit trail to agent reasoning
Record goal citation evidence so agent reasoning can be traced end-to-end.

- add core goal citation types, extraction helper, persistence schema, and store APIs for citation create/list workflows
- add CLI support and tests for goal citation flows, including command wiring and regression coverage
- update docs and add a published changeset for @runfusion/fusion describing the new audit-trail capability

Files changed:
 .changeset/fn-5663-goal-citation-audit-trail.md    |  10 +
 docs/agents.md                                     |  15 ++
 docs/cli-reference.md                              |   6 +-
 packages/cli/src/__tests__/bin.test.ts             |   2 +
 .../cli/src/__tests__/goals-citations-cli.test.ts  |  82 ++++++++
 packages/cli/src/bin.ts                            |  19 +-
 packages/cli/src/commands/goals.ts                 |  43 +++++
 packages/core/src/__tests__/db-migrate.test.ts     |  10 +-
 packages/core/src/__tests__/db.test.ts             |  34 ++--
 .../src/__tests__/goal-citation-extractor.test.ts  |  56 ++++++
 .../src/__tests__/goal-citations-store.test.ts     | 175 +++++++++++++++++
 packages/core/src/__tests__/goals-schema.test.ts   |   2 +-
 packages/core/src/__tests__/insight-store.test.ts  |  10 +-
 packages/core/src/__tests__/mission-store.test.ts  |   2 +-
 packages/core/src/__tests__/run-audit.test.ts      |   2 +-
 packages/core/src/__tests__/secrets-schema.test.ts |   6 +-
 .../core/src/__tests__/store-merge-queue.test.ts   |   2 +-
 packages/core/src/__tests__/task-documents.test.ts |   2 +-
 packages/core/src/db.ts                            |  51 ++++-
 packages/core/src/goal-citation-extractor.ts       |  56 ++++++
 packages/core/src/index.ts                         |  13 ++
 packages/core/src/store.ts                         | 210 ++++++++++++++++++++-
 packages/core/src/types.ts                         |  51 ++++-
 .../src/store/__tests__/roadmap-store.test.ts      |   4 +-
 24 files changed, 817 insertions(+), 46 deletions(-)

Fusion-Task-Id: FN-5663

Fusion-Task-Lineage: 720f2c4b-4363-464a-a76f-472ec6aca136
2026-05-29 08:25:38 -07:00
gsxdsm
009d569bdd Recovery: re-land fn goals CLI + pi tools onto main 2026-05-28 19:44:15 -07:00
gsxdsm
5eacd79b43 feat(FN-5584): merge fusion/fn-5584 2026-05-25 15:27:06 -07:00
gsxdsm
31c71a326a feat(FN-5513): merge fusion/fn-5513 2026-05-22 16:10:13 -07:00
Fusion (runfusion.ai)
fd202e9356 feat(FN-5329): remove orphan rescue and branch-recovery primitives from eng
Removes the branch-recovery CLI surface, orphan-rescue engine primitives, and their associated tests (over 1,500 lines deleted), while restoring a minimal prune-only orphan branch sweep with proper git audit mutation types. Documentation across `cli-reference.md`, `task-management.md`, and `AGENTS.m

Fusion-Task-Id: FN-5329
2026-05-20 16:43:27 -07:00
Fusion (runfusion.ai)
85da3ed658 docs(FN-5043): document fn pr create flags (--draft, --no-ai, --reviewer)
Fusion-Task-Id: FN-5043
Fusion-Task-Lineage: 25248b17-e49e-4b35-85fd-bcfaa02bbc1f
2026-05-18 06:46:32 -07:00
Fusion (runfusion.ai)
c814a503b5 docs(FN-4631): complete Step 4 — update CLI settings example
Fusion-Task-Id: FN-4631
Fusion-Task-Lineage: 05c5cab9-d372-45e3-b70f-ba2527407f77
2026-05-15 23:58:28 -07:00
Fusion (runfusion.ai)
de98e31582 feat(FN-4707): add experiment finalize section to CLI reference
Added documentation for the `experiment finalize` CLI command to the CLI reference guide.

Fusion-Task-Id: FN-4707
2026-05-15 21:22:46 -07:00
Fusion
dbf06513d8 feat(FN-4620): complete Step 9 — document interview board tools
Fusion-Task-Id: FN-4620
Fusion-Task-Lineage: d3d05e54-e137-46ee-bb5d-d71aa03e5a48
2026-05-15 11:47:04 -07:00
Fusion
1fe96eb1ad feat(FN-4484): update task-management and cli-reference documentation
Updates CLI reference and task management documentation to align with FN-4476 changes.

Fusion-Task-Id: FN-4484
2026-05-14 10:22:38 -07:00
Fusion
a2acb208c2 feat(FN-4152): complete Step 4 — document fn chat in CLI reference
Fusion-Task-Id: FN-4152
Fusion-Task-Lineage: cd26df5e-92f2-431a-950e-84a0fd81bd1f
2026-05-13 21:41:14 -07:00
Fusion
aecefac136 feat(FN-4098): document branch conflict recovery feature
Adds documentation for branch conflict recovery (FN-4098), covering the new CLI command, executor branch rename setting, recovery workflow, and delivery artifacts across the CLI reference, settings reference, and task management docs, with a changeset for the `@runfusion/fusion` package.

Fusion-Task-Id: FN-4098
2026-05-12 19:21:58 -07:00
Fusion
bddcc3a931 feat(FN-4068): add branch conflict detection and recovery for stale worktre
Implements branch conflict detection and recovery across the Fusion engine, CLI, and dashboard — surfacing git worktree conflicts when tasks conflict with unrelated branch state, and providing a recovery workflow to resolve them. The executor and worktree pool now integrate typed branch conflict che

Fusion-Task-Id: FN-4068
2026-05-12 17:14:29 -07:00
Fusion
097653eceb feat(FN-3633): document plugin trust policy feature
Adds plugin trust policy documentation across the CLI reference, settings reference, and a new plugin authoring guide, along with a patch-level changeset for `@runfusion/fusion`.

Fusion-Task-Id: FN-3633
2026-05-10 15:33:25 -07:00