Skip to content

feat(gmail): add --full flag and HTML stripping for thread display#25

Merged
steipete merged 2 commits intoopenclaw:mainfrom
salmonumbrella:feat/gmail-thread-full-output-v2
Jan 7, 2026
Merged

feat(gmail): add --full flag and HTML stripping for thread display#25
steipete merged 2 commits intoopenclaw:mainfrom
salmonumbrella:feat/gmail-thread-full-output-v2

Conversation

@salmonumbrella
Copy link
Copy Markdown
Contributor

Summary

  • Add --full flag to gog gmail thread get to show complete message bodies
  • Add HTML stripping patterns to clean up email content for terminal display
  • Default behavior now truncates messages to 500 chars with hint to use --full
  • Use runes for truncation to avoid breaking multi-byte UTF-8 characters
  • Show message count upfront (e.g., "Thread contains 5 message(s)")
  • Improve message header format (=== Message 1/5: ===)

Test plan

  • Unit tests for stripHTMLTags() covering script/style blocks, nested tags, whitespace
  • Build passes
  • Existing attachment/body parsing tests pass

🤖 Generated with Claude Code

salmonumbrella and others added 2 commits January 7, 2026 19:45
- Add HTML stripping patterns to remove script/style blocks and tags
- Add --full flag to show complete message bodies without truncation
- Default behavior now truncates to 500 chars with hint to use --full
- Use runes for truncation to avoid breaking UTF-8 characters
- Show message count upfront (e.g., "Thread contains 5 message(s)")
- Improve message header format (=== Message 1/5: <id> ===)
- Add comprehensive tests for stripHTMLTags()

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@steipete steipete force-pushed the feat/gmail-thread-full-output-v2 branch from 9b97c39 to e3216c2 Compare January 7, 2026 18:48
@steipete steipete merged commit 524f198 into openclaw:main Jan 7, 2026
3 checks passed
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.

2 participants