Skip to content

Replace raw ANSI codes with picocolors for cross-platform color support#45

Merged
that-github-user merged 1 commit intomainfrom
issue-27-ansi-colors
Mar 28, 2026
Merged

Replace raw ANSI codes with picocolors for cross-platform color support#45
that-github-user merged 1 commit intomainfrom
issue-27-ansi-colors

Conversation

@that-github-user
Copy link
Copy Markdown
Owner

Summary

  • Replace hand-rolled ANSI escape codes with picocolors (2.6KB, zero deps)
  • Automatic color support detection: TTY, NO_COLOR env, Windows cmd.exe
  • Fixed "Next steps" section to show correct thinktank apply commands
  • Removed unused displayProgress export

Change type

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • CI / infrastructure
  • Chore

Related issue

Closes #27

How to test

npm test  # 41 tests pass
NO_COLOR=1 npx tsx src/cli.ts list  # should show no color codes

Breaking changes

  • This PR introduces breaking changes

🤖 Generated with Claude Code

- Use picocolors (2.6KB, zero deps) instead of raw escape sequences
- Automatically detects color support (TTY, NO_COLOR env, Windows cmd)
- Removed unused displayProgress export
- Fixed "Next steps" to show correct thinktank apply commands

Closes #27

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@that-github-user
Copy link
Copy Markdown
Owner Author

Self-review: picocolors handles NO_COLOR, FORCE_COLOR, isTTY detection. Net -11 lines. Fixed incorrect git diff instructions in Next Steps. 41 tests pass, lint clean.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add ANSI color support detection for Windows cmd.exe compatibility

1 participant