@hung319/opencode-hive 1.3.7 → 1.3.8

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.
Files changed (2) hide show
  1. package/dist/index.js +16 -11
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -25699,6 +25699,12 @@ ${Object.entries(customAgentConfigs).sort(([left], [right]) => left.localeCompar
25699
25699
  allAgents["hygienic-reviewer"] = builtInAgentConfigs["hygienic-reviewer"];
25700
25700
  }
25701
25701
  Object.assign(allAgents, customSubagents);
25702
+ const primaryAgent = agentMode === "unified" ? "zetta" : "architect-planner";
25703
+ for (const [agentName, agentConfig] of Object.entries(allAgents)) {
25704
+ if (agentName !== primaryAgent && agentConfig && typeof agentConfig === "object") {
25705
+ agentConfig.mode = "subagent";
25706
+ }
25707
+ }
25702
25708
  const configAgent = opencodeConfig.agent;
25703
25709
  if (!configAgent) {
25704
25710
  opencodeConfig.agent = allAgents;
@@ -25716,21 +25722,20 @@ ${Object.entries(customAgentConfigs).sort(([left], [right]) => left.localeCompar
25716
25722
  delete configAgent["scout-researcher"];
25717
25723
  delete configAgent["forager-worker"];
25718
25724
  delete configAgent["hygienic-reviewer"];
25719
- if (configAgent.build) {
25720
- configAgent.build.mode = "subagent";
25721
- }
25722
- if (configAgent.plan) {
25723
- configAgent.plan.mode = "subagent";
25724
- }
25725
- if (configAgent.triage) {
25726
- configAgent.triage.mode = "subagent";
25725
+ const opencodeBuiltInAgents = ["build", "plan", "triage", "docs", "ask", "claude-code"];
25726
+ for (const agentName of opencodeBuiltInAgents) {
25727
+ if (configAgent[agentName]) {
25728
+ configAgent[agentName].mode = "subagent";
25729
+ }
25727
25730
  }
25728
- if (configAgent.docs) {
25729
- configAgent.docs.mode = "subagent";
25731
+ for (const [agentName, agentConfig] of Object.entries(allAgents)) {
25732
+ if (agentName !== primaryAgent && agentConfig && typeof agentConfig === "object") {
25733
+ agentConfig.mode = "subagent";
25734
+ }
25730
25735
  }
25731
25736
  Object.assign(configAgent, allAgents);
25732
25737
  }
25733
- opencodeConfig.default_agent = agentMode === "unified" ? "zetta" : "architect-planner";
25738
+ opencodeConfig.default_agent = primaryAgent;
25734
25739
  const configMcp = opencodeConfig.mcp;
25735
25740
  const mcpToAdd = builtinMcps;
25736
25741
  if (!configMcp) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hung319/opencode-hive",
3
- "version": "1.3.7",
3
+ "version": "1.3.8",
4
4
  "type": "module",
5
5
  "description": "OpenCode plugin for Agent Hive - from vibe coding to hive coding",
6
6
  "license": "MIT WITH Commons-Clause",