Skip to content

docs(extensions): move current-line lens to its own repo - #801

Merged
benvinegar merged 1 commit into
mainfrom
chore/extract-hunk-lens
Aug 18, 2026
Merged

docs(extensions): move current-line lens to its own repo#801
benvinegar merged 1 commit into
mainfrom
chore/extract-hunk-lens

Conversation

@benvinegar

Copy link
Copy Markdown
Member

Summary

  • move the current-line lens from Hunk's examples into modem-dev/hunk-lens
  • link the installable extension and its hunk extension install command from maintainer and user docs
  • keep Hunk's current-line pane integration coverage with a minimal test-owned fixture

Validation

  • bun run format:check
  • bun run lint
  • bun run typecheck
  • bun test ./src ./packages ./scripts ./test/cli ./test/session (2,973 passed, 10 skipped)
  • bun test test/pty/cursor-line.test.ts (9 passed)
  • bun run check:docs
  • standalone hunk-lens: format, lint, typecheck, and 3 unit tests
  • real PTY smoke run against the standalone extension
  • local managed install/list/remove smoke test

Merge note

modem-dev/hunk-lens was created private-first. Make it public before merging so the documentation links and GitHub install shorthand work for everyone.

This PR description was generated by Pi using gpt-5.6-sol

@vercel

vercel Bot commented Aug 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hunk-web Ready Ready Preview Aug 18, 2026 2:32am

Request Review

@benvinegar
benvinegar marked this pull request as ready for review August 18, 2026 13:31
@greptile-apps

greptile-apps Bot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR moves the current-line lens example to the external Hunk Lens repository while preserving host integration coverage through a test-owned fixture.

  • Replaces maintainer and user documentation links with the external extension and its installation command.
  • Removes the former in-tree example package.
  • Redirects PTY current-line tests to a minimal fixture under the test tree.

Confidence Score: 4/5

The PR appears safe to merge, with only a non-blocking indentation inconsistency in the new test fixture.

The removed example's in-repository test consumer is replaced by a loadable fixture preserving the asserted pane behavior, and the documented install shorthand matches the CLI parser; only the fixture's formatting convention needs attention.

Files Needing Attention: test/pty/fixtures/current-line-lens/index.tsx

Important Files Changed

Filename Overview
docs/extensions.md Replaces references to the removed example with the external Hunk Lens repository and supported install shorthand.
docs/extension-architecture.md Updates the architecture overview to describe external Hunk Lens as the current-line pane contract consumer.
test/pty/cursor-line.test.ts Redirects existing current-line pane integration tests from the removed example to the test-owned fixture.
test/pty/fixtures/current-line-lens/index.tsx Adds a minimal current-line pane fixture that preserves the tested rendering contract, but its indentation violates the mounted formatting guideline.
website/src/content/docs/docs/extend/custom-sidebars.md Updates website documentation to link and provide installation instructions for external Hunk Lens.
Prompt To Fix All With AI
### Issue 1
test/pty/fixtures/current-line-lens/index.tsx:7-18
**Use four-space fixture indentation**

The new fixture uses two-space indentation throughout the component and registration blocks instead of the repository's required four-space TypeScript indentation, creating inconsistent formatting and maintenance churn.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Reviews (1): Last reviewed commit: "docs(extensions): move current-line lens..." | Re-trigger Greptile

Comment on lines +7 to +18
function TestCurrentLineLens({ currentLine, theme, width }: ExtensionPaneProps): ReactNode {
if (!currentLine) return null;
const label = LABEL.slice(0, Math.max(0, width));
const rule = label + "─".repeat(Math.max(0, width - label.length));

return (
<box style={{ width, height: 3, flexDirection: "column", backgroundColor: theme.panel }}>
<text fg={theme.border}>{rule}</text>
{currentLine.render("old", width) as ReactNode}
{currentLine.render("new", width) as ReactNode}
</box>
);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Use four-space fixture indentation

The new fixture uses two-space indentation throughout the component and registration blocks instead of the repository's required four-space TypeScript indentation, creating inconsistent formatting and maintenance churn.

Context Used: guidelines.mdc Cursor rule (source)

Prompt To Fix With AI
This is a comment left during a code review.
Path: test/pty/fixtures/current-line-lens/index.tsx
Line: 7-18

Comment:
**Use four-space fixture indentation**

The new fixture uses two-space indentation throughout the component and registration blocks instead of the repository's required four-space TypeScript indentation, creating inconsistent formatting and maintenance churn.

**Context Used:** guidelines.mdc Cursor rule ([source](https://github.com/modem-dev/modem/blob/main/.cursor/rules/guidelines.mdc))

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@benvinegar
benvinegar merged commit 6ffea22 into main Aug 18, 2026
13 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.

1 participant