Skip to content

v0.11.0

Choose a tag to compare

@clemlesne clemlesne released this 17 Jun 15:15

Output rendering pass: long lines window around the match, color on a terminal and plain when piped, control bytes and Trojan-Source overrides stripped, truncation now states what it hid.

Upgrade. No re-index, no flag changes, no cache-layout change. Text output changed: denser gutter and a truncation notice — re-check anything that parses seek's output.

What changes for you

  • Color, auto-gated. File cyan, line numbers dim, matches bold red — terminal only. Piped output (agents, CI, | cat) stays plain, zero config. Precedence: NO_COLOR (non-empty) off → CLICOLOR_FORCE on (even piped) → else on when TERM set/≠dumb and stdout is a TTY.
  • Long lines windowed. Match line over 1024 B → cropped to ±512 B around its matches (never bisects a match), …+N bytes markers for dropped head/tail. Context lines over the cap tail-trimmed. Cuts on rune boundaries. No new flags.
  • Control-char & Trojan-Source sanitisation. C0/C1/DEL (tab kept) and the bidi / line-paragraph-separator code points behind CVE-2021-42574 stripped from output. Zero-width joiners kept (emoji, scripts).
  • Truncation announced. File cap → … N more files (showing X of Y); per-file match cap → … N more matches in this file. Was silent.
  • Denser gutter. Dropped line-number padding and two-space indent — now <lineNo> <content>. Fewer tokens per line.
  • Directly-openable multi-corpus headers. Header carries the absolute path (displayRoot + file name); tag collapses to bare [git] / [folder], was [git: /abs/root].

Breaking

  • Text output format changed — denser gutter, announced truncation, reshaped multi-corpus headers. Re-check output-scraping tooling. CLI flags, subcommands, and cache layout unchanged.

Dev/test

  • Deps: golang.org/x/term added; golang.org/x/sys → v0.46.0; cobra/pflag now direct.
  • Tests: color_gate_test.go, formatter_color_test.go (~490 lines), plus cli_root_test.go / main_test.go additions.
  • cicd/bench-field.sh: new Tok(content) / Tok(sym) columns — piped-output token count (tiktoken o200k_base via uv).
  • CI: ubuntu-26.04 runners (matrix expanded to 24.04/26.04 + macOS), coverage upload, govulncheck SARIF scan, dependency submission; test job timeout 25 min, make test-unit coverage profile under 18m.

Full changelog: v0.10.0...v0.11.0