Skip to content

feat(nvim): land delta location previews on master#92

Merged
aguil merged 7 commits into
masterfrom
fix/tmux-session-picker-shortcuts
Jun 11, 2026
Merged

feat(nvim): land delta location previews on master#92
aguil merged 7 commits into
masterfrom
fix/tmux-session-picker-shortcuts

Conversation

@aguil

@aguil aguil commented Jun 11, 2026

Copy link
Copy Markdown
Owner

Summary

Lands the commits from #91 (merged into fix/tmux-session-picker-shortcuts) onto master after #90. Brings delta-colored Telescope location previews, related Neovim/git fixes, and small dotfiles hygiene commits to the default branch.

Commits

  • fix(gh): export route helper for agent subprocesses
  • fix(nvim): disable delta paging in branch diff preview
  • feat(nvim): add delta location previews and shared diff base
  • feat(nvim): highlight reference row in delta location previews
  • chore(vale): add github to Dotfiles accept list
  • chore(gitignore): ignore Claude settings.local.json

Context

Test plan

  • chezmoi apply and restart Neovim
  • grr on a changed file: delta preview, reference row highlight, scroll/title
  • <leader>tJ toggles diff base; <leader>gb shows full branch diff
  • gh in agent subprocess: no route helper errors
  • .claude/settings.local.json ignored via global gitignore

Made with Cursor

aguil added 7 commits June 10, 2026 18:23
Agent shells (Claude Code, Cursor) rehydrate BASH_FUNC_gh from export -p
without private helpers, which printed "command not found:
_chez_gh_route_config_dir" on every gh invocation.

Guard the helper call when it is missing and export
_chez_gh_route_config_dir with gh in bash so per-directory routing
still works after rehydration. Mirror the guard in zsh with whence.

Verify: run gh in a Claude Code bash session; stderr stays clean and
auth routing matches the working directory.
Telescope branch-changes preview pipes diffs through delta via termopen.
The pseudo-TTY makes delta use its pager, so the preview stopped at the
first page instead of showing the full diff.

Pass --paging=never to delta so the entire highlighted diff lands in the
preview buffer and scrolls normally.

Verify: <leader>gb on a file with a long diff; preview shows all lines.
Wire custom Telescope qflist/grep previewers through delta for LSP
references and other location pickers, with scroll-to-line and file-at-line
fallback when the reference is outside diff hunks. Centralize git/jj diff
base toggle (<leader>tJ) and diff helpers in vcs.lua; reuse them for
branch-change and git preview pickers.

Enable dynamic_preview_title so preview borders show path:line. Avoid
CursorLine in terminal previews to keep the filter prompt in insert mode.

Verify: grr on changed files (scroll + title), branch picker diff preview,
and <leader>tJ toggling diff base.
Post-process delta output with awk to paint the LSP reference line using
TelescopePreviewLine/Visual bg (and fg when set), so busy diffs show a
selection-style row instead of inverse video. Cache preview buffers per
reference line so each selection gets its own highlighted render.

Verify: grr on a file with large diffs — reference row matches selected
line styling and scroll still centers on it.
Allow lowercase "github" in Vale prose checks for commit messages and
docs that reference the GitHub CLI or host.

Verify: vale on a doc containing "github" passes Dotfiles vocabulary.
Add a global ignore for **/.claude/settings.local.json so machine-local
Claude Code settings are not tracked when projects symlink or copy dotfiles
gitignore rules.

Verify: create .claude/settings.local.json under a repo; git status stays clean
with core.excludesfile pointing at this global gitignore.
feat(nvim): delta location previews for Telescope
@aguil aguil merged commit 185acc5 into master Jun 11, 2026
1 check passed
@aguil aguil deleted the fix/tmux-session-picker-shortcuts branch June 11, 2026 00:40
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