Skip to content

feat(config): support linematch in diffopt override#111

Merged
dlyongemallo merged 1 commit intomainfrom
diffopt_linematch
Apr 14, 2026
Merged

feat(config): support linematch in diffopt override#111
dlyongemallo merged 1 commit intomainfrom
diffopt_linematch

Conversation

@dlyongemallo
Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings April 14, 2026 16:28
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds support for overriding Neovim’s diffopt linematch setting while a Diffview tab is open, aligning config/docs/tests with the new capability.

Changes:

  • Extend per-view diffopt override logic to handle linematch:N (replace any existing linematch:* entry).
  • Add functional tests covering apply/replace/no-op behavior for linematch overrides.
  • Document the new diffopt.linematch config key in both Lua defaults and :h diffview-config-diffopt.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
lua/diffview/scene/view.lua Applies diffopt.linematch overrides by removing existing linematch:* and appending linematch:<N> while the view is active.
lua/diffview/tests/functional/view_spec.lua Adds functional coverage for configuring/replacing/restoring linematch in diffopt overrides.
lua/diffview/config.lua Updates defaults comment to include linematch as a supported diffopt override key.
doc/diffview.txt Documents diffopt.linematch, its purpose, and updates the example config.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread lua/diffview/scene/view.lua
@dlyongemallo dlyongemallo merged commit 6120ba7 into main Apr 14, 2026
6 checks passed
@dlyongemallo dlyongemallo deleted the diffopt_linematch branch April 14, 2026 16:39
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