Skip to content

feat: Add hierarchical file tree with expand/collapse#50

Merged
agavra merged 3 commits intoagavra:mainfrom
airscholar:feat/directory-grouping
Jan 11, 2026
Merged

feat: Add hierarchical file tree with expand/collapse#50
agavra merged 3 commits intoagavra:mainfrom
airscholar:feat/directory-grouping

Conversation

@airscholar
Copy link
Copy Markdown
Contributor

@airscholar airscholar commented Jan 11, 2026

Summary

  • Add hierarchical file tree view with expand/collapse functionality
  • Use Space to select files and toggle directory expansion
  • Use o/O to expand/collapse all directories
  • Underline styling for selected items in file list
  • Tree structure with ▾/▸ icons for expanded/collapsed directories
  • Auto-expand parent directories when jumping to file
  • Sync selection between file list and diff panels
  • Add 7 unit tests for tree functionality

Copy link
Copy Markdown
Owner

@agavra agavra left a comment

Choose a reason for hiding this comment

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

I love this! So much so I think we should make it the only option. Some feedback inline

@airscholar airscholar changed the title feat: Add directory grouping toggle for file list feat: Add hierarchical file tree with expand/collapse Jan 11, 2026
Adds directory grouping (press 't') to organize files by directory structure with folder headers.

- Added 't' keybinding to toggle directory grouping
- Files are sorted and grouped by directory when enabled
- Smart path truncation for long directory names
- Status bar shows 't:tree' hint
- Add FileTreeItem enum and expanded_dirs state to App
- Use Space to select files and expand/collapse directories
- Use o/O to expand/collapse all directories
- Underline styling for selected items
- Tree structure with ▾/▸ icons for expanded/collapsed dirs
- Auto-expand parent directories when jumping to file
- Sync selection when navigating between panels
- Add 7 unit tests for tree functionality
@airscholar airscholar force-pushed the feat/directory-grouping branch from b29aee7 to 90f90ab Compare January 11, 2026 20:09
Copy link
Copy Markdown
Owner

@agavra agavra left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks @airscholar

@agavra agavra merged commit 056006b into agavra:main Jan 11, 2026
4 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.

2 participants