Skip to content

feat: export static diff renderer - #686

Open
privatenumber wants to merge 1 commit into
modem-dev:mainfrom
privatenumber:feat/static-diff-export
Open

feat: export static diff renderer#686
privatenumber wants to merge 1 commit into
modem-dev:mainfrom
privatenumber:feat/static-diff-export

Conversation

@privatenumber

Copy link
Copy Markdown

Problem

Hunk can render unified patches as terminal-friendly ANSI text for constrained pager hosts, but that renderer is only available inside the CLI. An integration that already has a patch must either start the interactive application or reimplement the presentation layer.

For example, a terminal host can receive git diff output and need a colored stack or split view without taking over input or the alternate screen.

Changes

  • Publish hunkdiff/static with renderStaticDiff(patch, options), returning Hunk's sanitized ANSI output without starting an interactive review.
  • Keep the static API and pager fallback on one patch parsing and rendering path, including filename-based syntax detection.
  • Package the Node-targeted entry and declarations, verify the built export during the pack check, and document its options.

@greptile-apps

greptile-apps Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

PR author is not in the allowed authors list.

@vercel

vercel Bot commented Aug 8, 2026

Copy link
Copy Markdown

@privatenumber is attempting to deploy a commit to the Modem Team on Vercel.

A member of the Team first needs to authorize it.

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.

1 participant