Skip to content

feat(bob): support global subagents via ~/.bob/settings/custom_modes.yaml - #3918

Merged
dyoshikawa merged 4 commits into
mainfrom
resolve-issue-3074-bob-global-modes
Nov 20, 2026
Merged

dyoshikawa merged 4 commits into
mainfrom
resolve-issue-3074-bob-global-modes

Conversation

@dyoshikawa

@dyoshikawa dyoshikawa commented Nov 20, 2026 •

Copy link
Copy Markdown
Owner

Refs #3074

Summary

Both Bob custom-modes pages now give the same user-level file, ~/.bob/settings/custom_modes.yaml. The Bob Shell page used to say ~/.bob/custom_modes.yaml and now matches the Bob IDE page. That disagreement was the only thing keeping the bob subagents adapter project-only, so this PR adds global scope:

  • BobSubagent.getSettablePaths({ global: true }) returns .bob/settings/custom_modes.yaml. The project file .bob/custom_modes.yaml is unchanged.
  • RooSubagent.fromRulesyncSubagents / fromRulesyncSubagent / fromFile now pass the global flag through to getSettablePaths. Roo and Zoo Code still return . for both scopes and stay project-only, so their behavior does not change.
  • supportsGlobal: true for bob in the subagents processor.
  • The global file is unversioned, and Bob IDE's "Edit Global Modes" also writes it, so rulesync does not own it. In global mode only, the aggregate is merged into the existing file by slug: generated modes replace their counterparts in place, every other mode is kept as written, and new modes are appended. The file is never deleted, so --delete leaves it alone. A file that cannot be read as a customModes document is an error rather than being overwritten. Project-scope behavior is unchanged.
  • Updated the path comments, the IBM Bob subagents note in docs/reference/file-formats.md (including the global merge behavior), the generated docs content, and the supported-tools table.

Remaining in #3074

  • PermissionRequest / PermissionResolved hook events (Bob IDE 2.3.0): watch item. The lifecycle-hooks pages do not document their payload, matcher or decision output yet.
  • The IDE plugins/ subdirectory: watch item, still documented only in the changelog.

Tests

  • Unit tests: global generate path, the single-subagent path, and global import from ~/.bob/settings/custom_modes.yaml (bob-subagent.test.ts). bob is added to the processor's global target list.
  • Unit tests: project-file ownership is unchanged, the global file is not deletable, the slug merge works, and an unreadable file is refused.
  • E2E: bob is added to the global subagents generate matrix. A global generate keeps an existing hand-written mode, and a global generate --delete with no bob-targeted subagent leaves the file in place.
  • pnpm cicheck passes.

🤖 Generated with Claude Code

https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4

dyoshikawa and others added 4 commits November 20, 2026 11:38
Both the Bob IDE and Bob Shell custom-modes pages now name
~/.bob/settings/custom_modes.yaml as the user-level file, so the bob
subagents adapter supports --global. The Roo-style modes base class now
threads the global flag through to getSettablePaths when generating and
importing.

Refs #3074

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4
~/.bob/settings/custom_modes.yaml is unversioned and Bob IDE's "Edit
Global Modes" writes it too, so a global generate now merges the
generated modes into it by slug, keeping every other mode, and the orphan
sweep no longer deletes it. The project file stays wholly owned by
rulesync.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4
…merge

The global custom modes merge now writes the generated modes back into
the parsed document, so other top-level keys survive, and drops later
duplicates of a generated slug with a warning instead of leaving a stale
copy behind.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4
…b-global-modes

# Conflicts:
#	src/generated/docs-content.ts
@dyoshikawa
dyoshikawa merged commit 429fefb into main Nov 20, 2026
10 checks passed
@dyoshikawa
dyoshikawa deleted the resolve-issue-3074-bob-global-modes branch November 20, 2026 03:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant