Repository navigation
feat: file tree folding, hierarchy navigation, and combined directory diffs - #33
Merged
Merged
Conversation
… combined folder diffs
Owner
|
All great PRs btw! I'll review them tonight, thanks so much! |
… view - pin current file separator to viewport top in multi-file unified and split diffs with sticky header helpers - add preview_placeholder rows for unavailable previews including centered binary placeholder - fix row-to-line mapping, fallback index, and selection/overlay hit-testing for reserved sticky row - ignore mouse selection on sticky header rowsfeat(pager): add sticky file headers and preview placeholders to diff view - pin current file separator to viewport top in multi-file unified and split diffs with sticky header helpers - add preview_placeholder rows for unavailable previews including centered binary placeholder - fix row-to-line mapping, fallback index, and selection/overlay hit-testing for reserved sticky row - ignore mouse selection on sticky header rows
Show each worktree’s directory name instead of its full path, align branch names using Unicode display width, and label the main worktree. Render submodule lists consistently across screen modes and add coverage for both lists.
Show divergent commits between two refs with ahead/behind counts, side indicators, paging, and commit-file previews. Add commit-aware diff and grep behavior, panel focus/navigation, and revision validation.
- Shift + / shift - work - Mouse resizing - Responsive layout based on size - shift-tab cycles backwards
* feat(pager): add inline image diff previews for raster files - Render Before/After previews for PNG, JPEG, GIF, WebP, BMP, ICO, and TIFF in Kitty and Ghostty, with Added/Deleted full-width states backed by worktree, index, and revision blobs - Add background decode with memory/dimension limits, 20 MiB cap, and striped binary fallback for unsupported terminals, oversized files, and corrupt images - Support capped inline image sections in folder diffs across split/unified and wrapped views with viewport-driven loading and cache-aware unloading - Add diff path parsing for quoted/renamed headers, terminal graphics protocol handling, `LAZYGITRS_IMAGE_PREVIEW` opt-out/experimental flags, and tmux/screen/Zellij fallback * refactor(pager): isolate image preview capabilities and sources * fix(input): preserve Alt shortcuts when filtering Kitty replies
…s and head (Blankeos#34) Co-authored-by: Blankeos <carloantonioct@gmail.com>
Use '.' to select the first visible tree child and apostrophe to toggle Commit Details across commit contexts. Update contextual help and the panel's top-right toggle hint to match; explicit tree remappings retain precedence while a tree is active. Show only the configured fold/unfold shortcut in active file-tree list footers, including compare mode. Hide it in flat lists and diff focus, omit disabled bindings, and keep hierarchy navigation in contextual '?' help rather than the footer. Remove Commit Details footer hints. Document the final defaults and footer policy, and add regression coverage for keybinding defaults, remapping precedence, details contexts/help, both details-panel layouts, and contextual normal/compare footers.
Blankeos
approved these changes
Oct 6, 2026
Blankeos
left a comment
Owner
There was a problem hiding this comment.
Reviewed and locally retested the integrated file-tree changes and follow-up fixes. All 302 tests pass with cargo test --locked; cargo fmt --check, cargo build --locked, and git diff --check pass. Confirmed defaults: '.' selects the first visible child; apostrophe toggles Commit Details. Footers show only configured fold/unfold in active tree lists, with hierarchy navigation in contextual help. Navigation preserves viewport/diff refresh behavior and Enter preserves screen layout. Approved for squash merge following user retest.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Hi @Blankeos and contributors! 👋
This PR enhances the file tree experience across
lazygitrsby introducing explicit directory folding, rapid tree hierarchy traversal (parent/child/siblings), and direct combined folder diffs.All new actions are fully customizable in
config.ymland integrated with the Command Palette / Help popup and status bar.What's Changed & Key Advantages
Explicit Directory Folding (
-by default):-(customizable viakeybinding.universal.foldDirectory) folds and unfolds the selected directory node, including the root node (/), without confusing it with selecting child files.Combined Directory Diff Inspection (
Enteron directories):Enteron any directory node (or root/) focuses the diff view and displays a unified combined diff of all modified child files under that folder. This provides a great high-level overview of what changed in an entire module or directory before diving into individual files.Fast Tree Hierarchy & Sibling Navigation (
,,.,<,>by default):,(parent -keybinding.universal.treeParent): Jumps straight up to the parent directory node..(first child -keybinding.universal.treeChild): Jumps into the first child node of the directory.<(prev sibling -keybinding.universal.treePrevSibling): Jumps to the previous sibling node at the same tree depth.>(next sibling -keybinding.universal.treeNextSibling): Jumps to the next sibling node at the same tree depth.100% Configurable & Dynamic UI:
foldDirectory,treeParent,treeChild,treePrevSibling, andtreeNextSiblingtoUniversalKeybinding.~/.config/lazygit/config.ymlunderuniversal:?) and bottom status bar dynamically reflect the active user configuration..does not accidentally toggle commit details when navigating commit file trees.Testing
test_tree_navigation).test_tree_keybindings_defaults_and_deserialization).cargo test).cargo fmt.Thank you for creating and maintaining
lazygitrs! Feedback and reviews are warmly welcomed.