From dt-brigid
Covers Spectre.Console markup escaping, IRenderable namespace, CommandApp Execute signature, live display initialization, and Layout structure. Load when building CLI output, TUI dashboards, or Spectre.Console.Cli command definitions.
npx claudepluginhub dreamteam-hq/brigid --plugin dt-brigidThis skill uses the workspace's default tool permissions.
Patterns for Spectre.Console (rendering) and Spectre.Console.Cli (CLI framework), used in `scripts/diag.cs`.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Checks Next.js compilation errors using a running Turbopack dev server after code edits. Fixes actionable issues before reporting complete. Replaces `next build`.
Patterns for Spectre.Console (rendering) and Spectre.Console.Cli (CLI framework), used in scripts/diag.cs.
Spectre.Console@0.54.0 — rendering (Panel, Table, BarChart, Layout, Live, Markup)Spectre.Console.Cli@0.53.1 — CLI framework (CommandApp, Command). Separate repo, versioned independently.Spectre markup uses [style]text[/] syntax. Literal square brackets must be doubled:
// WRONG — Spectre tries to parse "x" as a color
cols.Add($"[bold red]{cursor}[{check}][/]");
// RIGHT — renders literal [x] or [ ]
cols.Add($"[bold red]{cursor}[/][[{check}]]");
IRenderable is in Spectre.Console.Rendering, not Spectre.Console. Add the using when returning renderables from helper methods:
using Spectre.Console.Rendering;
In Spectre.Console.Cli 0.53.1, the Execute override requires three parameters:
public override int Execute(CommandContext context, TSettings settings, CancellationToken ct)
The two-parameter overload no longer compiles.
Populate the Layout with real data before calling AnsiConsole.Live(layout).Start(). If you initialize with placeholder Markup ("Loading..."), it flashes for one frame.
// Populate BEFORE entering Live
RefreshDisplay(layout, cpuSampler, killMode);
AnsiConsole.Live(layout)
.AutoClear(true)
.Start(ctx => { /* loop */ });
Layout divides terminal space using Ratio(). Use SplitRows for vertical and SplitColumns for horizontal division. Access children by name:
var layout = new Layout("Root")
.SplitRows(
new Layout("Header").Ratio(1),
new Layout("Content").Ratio(4));
layout["Header"].Update(new Panel(...));