Merge pull request '[agent/codex:gpt-5.4-mini] Read ~/spec/code/core/go/cli/RFC.md fully. Find features des...' (#81) from agent/read---spec-code-core-go-cli-rfc-md-full into dev
All checks were successful
Security Scan / security (push) Successful in 25s

This commit is contained in:
Virgil 2026-04-02 11:26:08 +00:00
commit ba456e4560
2 changed files with 9 additions and 4 deletions

View file

@ -16,7 +16,7 @@ func Blank() {
// Echo translates a key via i18n.T and prints with newline.
// No automatic styling - use Success/Error/Warn/Info for styled output.
func Echo(key string, args ...any) {
fmt.Println(i18n.T(key, args...))
fmt.Println(compileGlyphs(i18n.T(key, args...)))
}
// Print outputs formatted text (no newline).
@ -112,9 +112,9 @@ func Dim(msg string) {
// Progress prints a progress indicator that overwrites the current line.
// Uses i18n.Progress for gerund form ("Checking...").
func Progress(verb string, current, total int, item ...string) {
msg := i18n.Progress(verb)
msg := compileGlyphs(i18n.Progress(verb))
if len(item) > 0 && item[0] != "" {
fmt.Fprintf(os.Stderr, "\033[2K\r%s %d/%d %s", DimStyle.Render(msg), current, total, item[0])
fmt.Fprintf(os.Stderr, "\033[2K\r%s %d/%d %s", DimStyle.Render(msg), current, total, compileGlyphs(item[0]))
} else {
fmt.Fprintf(os.Stderr, "\033[2K\r%s %d/%d", DimStyle.Render(msg), current, total)
}
@ -127,7 +127,7 @@ func ProgressDone() {
// Label prints a "Label: value" line.
func Label(word, value string) {
fmt.Printf("%s %s\n", KeyStyle.Render(i18n.Label(word)), compileGlyphs(value))
fmt.Printf("%s %s\n", KeyStyle.Render(compileGlyphs(i18n.Label(word))), compileGlyphs(value))
}
// Scanln reads from stdin.

View file

@ -107,11 +107,13 @@ func TestSemanticOutput_GlyphShortcodes(t *testing.T) {
UseASCII()
out := captureOutput(func() {
Echo(":check:")
Success("done :check:")
Task(":cross:", "running :warn:")
Section(":check: audit")
Hint(":info:", "apply :check:")
Label("status", "ready :warn:")
Progress("check", 1, 2, ":warn: repo")
})
for _, want := range []string{"[OK]", "[FAIL]", "[WARN]"} {
@ -119,4 +121,7 @@ func TestSemanticOutput_GlyphShortcodes(t *testing.T) {
t.Fatalf("expected output to contain %q, got %q", want, out)
}
}
if !strings.Contains(out, "[WARN] repo") {
t.Fatalf("expected progress item shortcode to be rendered, got %q", out)
}
}