( host: SlashCommandHost, beforeList: readonly PluginSummary[], summary: PluginSummary, )
| 486 | const PLUGIN_RELOAD_HINT = 'Run /new or /reload to apply plugin changes.'; |
| 487 | |
| 488 | function showPluginInstallResult( |
| 489 | host: SlashCommandHost, |
| 490 | beforeList: readonly PluginSummary[], |
| 491 | summary: PluginSummary, |
| 492 | ): void { |
| 493 | const previous = beforeList.find((entry) => entry.id === summary.id); |
| 494 | const serverWord = summary.mcpServerCount === 1 ? 'server' : 'servers'; |
| 495 | const mcpHint = |
| 496 | summary.mcpServerCount > 0 |
| 497 | ? ` Declares ${summary.mcpServerCount} MCP ${serverWord}; enabled by default and configurable from /plugins.` |
| 498 | : ''; |
| 499 | const action = describeInstallAction(previous, summary); |
| 500 | host.showStatus(`${action} (${summary.id}).${mcpHint}`); |
| 501 | host.showStatus(PLUGIN_RELOAD_HINT, 'warning'); |
| 502 | } |
| 503 | |
| 504 | function describeInstallAction( |
| 505 | previous: PluginSummary | undefined, |
no test coverage detected