summaryrefslogtreecommitdiff
path: root/internal/textutil
AgeCommit message (Collapse)Author
2026-03-17Fix bugs, remove duplication, and clean up code quality issuesPaul Buetow
- Log swallowed JSON unmarshal errors in stats and LSP handlers - Fix debug log file handle leak in tmuxedit (return closer from initDebugLog) - Check f.Close() errors on write paths in promptstore and tmuxedit - Fix cacheGet TOCTOU race by using single write lock - Fix readInput to use passed stdin reader instead of os.Stdin.Stat() - Remove 45 'moved to' comment tombstones from lsp/handlers.go - Deduplicate canonicalProvider wrappers (use llmutils.CanonicalProvider directly) - Remove SetWindow side effect from stats.TakeSnapshot (pure read now) - Move duplicated splitLines to textutil.SplitLinesBytes - Collapse StatusSink.SetGlobal 10 params into GlobalStatus struct - Simplify LRU touchLocked to in-place delete-and-append Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-02-08Add unit tests to improve coverage above 80% targetPaul Buetow
Implement comprehensive unit tests for critical internal packages to increase overall test coverage from 80.9% to 81.8%, providing a buffer above the 80% threshold specified in project guidelines. Changes: - Add config parsing tests (parseTemperatureValue, decodeModelEntry, resolvedModel, parseSurfaceEntries) - Add HumanBytes utility tests with edge cases and boundary values - Fix HumanBytes bug: corrected suffix array indexing (off-by-one error) - Fix HumanBytes to handle negative values correctly - Add comprehensive shellJoin and isSafeBare tests for shell escaping - Update comments to reflect actual behavior and implementation details Coverage impact: - internal/appconfig: Improved config parsing function coverage - internal/textutil: HumanBytes now at 100% coverage (fixed bug in process) - internal/tmux: shellJoin and isSafeBare now at 100% coverage - Overall project: 80.9% → 81.8% (+0.9%) All tests pass. Code formatted with gofumpt. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-09-08docs: move tmux documentation to its own filePaul Buetow
2025-09-08tmux: colored LLM status with provider + stats; add start heartbeat for ↵Paul Buetow
LSP/CLI/TUI; theme support via HEXAI_TMUX_STATUS_THEME and HEXAI_TMUX_STATUS_FG/BG; docs: update tmux options and add Helix+tmux quickstart
2025-09-06more testsPaul Buetow