You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This report presents findings from a full scan of Go source files in pkg/ and cmd/ for console output patterns, Lipgloss styling usage, and Huh interactive form implementations.
pkg/cli/audit_report_render.go (581 lines) uses console.FormatSectionHeader() and console.RenderTable() for structure but falls back to raw fmt.Fprintf(os.Stderr, ...) with hardcoded emoji for list items and findings — bypassing the consistent styling system.
View specific examples
// List items — bypasses console.FormatListItemfmt.Fprintf(os.Stderr, " • %s (%s)", file.Path, formattedSize) // line 75fmt.Fprintf(os.Stderr, " • %s\n", tool.Tool) // line 89fmt.Fprintf(os.Stderr, " • %s: %s\n", failure.ServerName, ...) // line 110// Severity indicators — hardcoded emoji, inconsistent with console package iconsfmt.Fprintf(os.Stderr, " 🔴 %s [%s]\n", console.FormatErrorMessage(finding.Title), ...) // line 449fmt.Fprintf(os.Stderr, " 🟡 %s [%s]\n", finding.Title, ...) // line 469fmt.Fprintf(os.Stderr, " ℹ️ %s [%s]\n", finding.Title, ...) // line 479// Network stats — raw emoji instead of console formattersfmt.Fprintf(os.Stderr, " ✓ %s (%d requests)\n", domain, ...) // line 360fmt.Fprintf(os.Stderr, " ✗ %s (%d requests)\n", domain, ...) // line 371
Recommendations:
Use console.FormatListItem(item) for bullet list entries
Replace console.FormatErrorMessage(finding.Title) embedded in a raw printf with a structured helper
Consider adding console.FormatFindingMessage(severity, title, category string) to standardize severity rendering
⚠️ Raw Diagnostic Messages in compile_helpers.go
pkg/cli/compile_helpers.go bypasses console formatters for error list rendering:
// Lines 300, 315 — should use console.FormatErrorMessagefmt.Fprintf(os.Stderr, " ✗ %s\n", filepath.Base(failure.Path))
fmt.Fprintf(os.Stderr, " ✗ %s\n", workflow)
// Line 200 — should use console.FormatInfoMessagefmt.Fprintln(os.Stderr, "Watching for file changes")
⚠️ Raw Diagnostic Messages in deps_report.go and mcp_inspect_mcp.go
View details
pkg/cli/deps_report.go:
// Lines 176, 184 — hardcoded emoji with raw messagefmt.Fprintf(os.Stderr, "🔴 CRITICAL: Address %d security %s immediately\n", ...)
fmt.Fprintf(os.Stderr, "⚠️ Reduce v0.x exposure from %.0f%% to <30%%\n", ...)
// Should be:fmt.Fprintln(os.Stderr, console.FormatErrorMessage(fmt.Sprintf("CRITICAL: Address %d security %s immediately", ...)))
fmt.Fprintln(os.Stderr, console.FormatWarningMessage(fmt.Sprintf("Reduce v0.x exposure from %.0f%% to <30%%", ...)))
pkg/cli/mcp_inspect_mcp.go:494:
// Raw markdown-style bold in terminal outputfmt.Fprintf(os.Stderr, "⚠️ **Destructive:** May perform destructive updates\n")
// Should be:fmt.Fprintln(os.Stderr, console.FormatWarningMessage("Destructive: May perform destructive updates"))
Opportunities
ℹ️ Huh Form Theming
No form in the codebase uses .WithTheme() to align interactive field colors with pkg/styles. The Charmbracelet Huh library supports custom themes via huh.NewTheme(). Applying a theme derived from pkg/styles colors would create visual consistency between form prompts and the rest of the CLI output.
// Opportunity: Create a shared theme derived from pkg/styles// pkg/console/theme.govarAWTheme= huh.NewTheme(...)
// Usage
huh.NewForm(...).
WithAccessible(console.IsAccessibleMode()).
WithTheme(console.AWTheme)
ℹ️ Inline lipgloss.NewStyle() in console.go RenderTable
pkg/console/console.go:168 uses lipgloss.NewStyle() directly in the styleFunc within RenderTable. These could reference pkg/styles constants for better centralization.
Recommendations by Priority
Priority
Action
Files
High
Remove duplicate emoji from Format* call arguments
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
This report presents findings from a full scan of Go source files in
pkg/andcmd/for console output patterns, Lipgloss styling usage, and Huh interactive form implementations.Totals scanned: ~250 non-test
.gofiles | 3,421fmt.Print*usages | 1,556console.*usagesSummary
pkg/styleswithAdaptiveColorapplyStyle()gates all styling;pkg/ttyused consistently.WithAccessible(console.IsAccessibleMode())FormatSuccessMessage("✓ ...")duplicates the built-in iconaudit_report_render.go,deps_report.gomix styles.WithTheme()to match the palette inpkg/stylesStrengths
✅ Lipgloss: Adaptive Color System (pkg/styles)
pkg/styles/theme.godefines a thorough adaptive palette with documented light/dark hex values:All format functions in
pkg/console/console.goapply styles conditionally viaapplyStyle():This cleanly prevents ANSI codes from polluting piped output.
✅ Huh Forms: Consistent Accessibility Support
Every interactive form across 13+ files correctly uses:
IsAccessibleMode()checksACCESSIBLE,TERM=dumb, andNO_COLORenvironment variables — a solid multi-signal approach.Files with correct accessibility usage:
run_interactive.go,add_interactive_engine.go,add_interactive_workflow.go,add_interactive_auth.go,add_interactive_schedule.go,add_interactive_orchestrator.go,add_interactive_git.go,engine_secrets.go,interactive.go,console/input.go,console/confirm.go.✅ Output Routing: stdout vs stderr
Structured data correctly routes to stdout for piping:
fmt.Println(string(jsonBytes))— JSON output (health, status, run)fmt.Println(hash)— Hash outputfmt.Println(mermaidGraph)— Graph outputfmt.Println(string(result.State))— Checks stateDiagnostic output correctly routes to stderr with
fmt.Fprintln(os.Stderr, console.Format*(...)).Issues Found
FormatSuccessMessage,FormatWarningMessage, andFormatInfoMessagealready prepend icons (✓,⚠,ℹ). Passing emoji-prefixed strings to these functions results in duplicated icons in TTY mode.Affected files and lines:
pkg/cli/fix_command.go:233,251FormatInfoMessage("✓ No fixes needed")ℹ ✓ No fixes neededpkg/cli/fix_command.go:322FormatSuccessMessage("✓ "+fileName)✓ ✓ filenamepkg/cli/fix_command.go:327FormatWarningMessage("⚠ "+fileName)⚠ ⚠ filenamepkg/cli/run_interactive.go:100FormatSuccessMessage("✓ Workflow dispatched successfully!")✓ ✓ Workflow...pkg/cli/update_extension_check.go:65,87FormatSuccessMessage("✓ gh-aw extension...")✓ ✓ gh-aw...pkg/cli/project_command.go:158,179,186,195FormatSuccessMessage("✓ ...")✓ ✓ ...pkg/cli/upgrade_command.go:187,224,288FormatSuccessMessage("✓ ...")✓ ✓ ...Fix: Remove emoji prefix from the string passed to the formatter:
pkg/cli/audit_report_render.go(581 lines) usesconsole.FormatSectionHeader()andconsole.RenderTable()for structure but falls back to rawfmt.Fprintf(os.Stderr, ...)with hardcoded emoji for list items and findings — bypassing the consistent styling system.View specific examples
Recommendations:
console.FormatListItem(item)for bullet list entriesconsole.FormatErrorMessage(finding.Title)embedded in a raw printf with a structured helperconsole.FormatFindingMessage(severity, title, category string)to standardize severity renderingpkg/cli/compile_helpers.gobypasses console formatters for error list rendering:View details
pkg/cli/deps_report.go:pkg/cli/mcp_inspect_mcp.go:494:Opportunities
ℹ️ Huh Form Theming
No form in the codebase uses
.WithTheme()to align interactive field colors withpkg/styles. The Charmbracelet Huh library supports custom themes viahuh.NewTheme(). Applying a theme derived frompkg/stylescolors would create visual consistency between form prompts and the rest of the CLI output.ℹ️ Inline
lipgloss.NewStyle()in console.go RenderTablepkg/console/console.go:168useslipgloss.NewStyle()directly in thestyleFuncwithinRenderTable. These could referencepkg/stylesconstants for better centralization.Recommendations by Priority
Format*call argumentsfix_command.go,run_interactive.go,update_extension_check.go,project_command.go,upgrade_command.goaudit_report_render.goconsole.FormatErrorMessage/InfoMessagefor compile error listscompile_helpers.gomcp_list_tools.go,mcp_inspect_mcp.godeps_report.go.WithTheme()for palette consistencyReferences: §23026731124
Beta Was this translation helpful? Give feedback.
All reactions