# The dsh-local-agent-claude-code bundle patch: delegate dsh agents to the
# local Claude Code CLI under a scoped CLAUDE_CONFIG_DIR, and surface its
# session records. The family core row (`local-agent`, shared scoped-homes
# root) lives in the framework bundle @khorsheed/dsh-local-agent's own patch.
# This bundle declares that package as an npm dependency, which makes the
# core's module resolvable — it does NOT mount the core row: `dsh plugin add`
# reconciles only the profile's direct dependencies, so the core must be
# installed explicitly alongside this bundle, or this provider stays pending.
# No other patch inserts the core row id.
#
# Exactly ONE row is inserted: the provider (this bundle's plugin registers the
# `claude-code` harness — CLAUDE_CONFIG_DIR scoped home, `claude auth login`
# browser flow, project-file session records). The `subagent_claude_code`
# delegation tool is no longer a profile-root row: since the family fold it
# ships as this package's `./tool` composition entry
# (`name: '@khorsheed/dsh-local-agent-claude-code/tool'` in an agent preset),
# granted per session — the dev preset's `tool-subagent-claude-code-local` row
# is the grant point. The family keeps the official model-facing name
# `subagent_claude_code`: the official preset row of that name ships
# `disabled: true`, and this patch disables the profile-root row too (below)
# so a community install can never register two `subagent_claude_code` tools.
# A user who deliberately re-enables the official row in their own preset
# layer gets a loud duplicate-name conflict — by design, they must choose one.
# The family tool keeps its continuation parameter: a later round may pass the
# dsh child session id returned by the first delegation to continue the same
# claude conversation.
#
# The provider starts no claude process until a tool call or /claude-code login.

- id: tool-subagent-claude-code
  disabled: true

- insert:
    - id: local-agent-claude-code
      name: '@khorsheed/dsh-local-agent-claude-code'
