Git History Explorer is a terminal-based interactive application that analyzes Git repository commit metadata and displays visualizations of author activity. It provides both an overview of all contributors and detailed individual author analysis through an intuitive text-based user interface.
- Analyze the complete commit history of any Git repository
- Display comprehensive commit statistics for each author:
- Total number of commits
- First commit date
- Last commit date
- Days between first and last commit
- Handle different time zones and daylight saving time changes automatically
- Optimized for performance with large repositories using Polars data processing
- Overview Mode: Shows commit activity patterns across all authors
- Author-Specific Mode: Display individual author commit patterns
- Color-Coded Intensity: Visual representation of commit frequency (4 intensity levels)
- Calendar Year View: Commits mapped to current year calendar for easy pattern recognition
- Real Data: Uses actual commit timestamps and dates from the repository
- Navigation: Use arrow keys (↑↓) to browse through authors
- Author Selection: Press Enter to select/deselect authors for detailed heatmap view
- Sorting: Sort by any column using number keys (1-5):
- 1: Email
- 2: Commits
- 3: First Commit
- 4: Last Commit
- 5: Days Between
- Reverse Sort: Toggle sort direction with R key
- Search: Filter authors by email using / key
- Exit: Quit with Q or Esc
- Real-time author search by email address
- Instant filtering as you type
- Maintains sorting preferences while filtering
Run the application in your terminal:
git_history_explorer
This will analyze the Git repository in the current directory.
Analyze a specific repository:
git_history_explorer --path /path/to/your/repo
git_history_explorer -p /path/to/your/repo
Key | Action |
---|---|
↑ ↓ |
Navigate through author list |
Enter |
Select/deselect author for heatmap view |
1 |
Sort by email |
2 |
Sort by commit count |
3 |
Sort by first commit date |
4 |
Sort by last commit date |
5 |
Sort by days between commits |
R |
Reverse sort direction |
/ |
Enter search mode |
Q Esc |
Quit application |
The application interface is divided into four main sections:
- Header: Shows repository path and total authors (with selected author info)
- Heatmap: Visual commit activity chart (25% of screen height)
- Author Table: Sortable and filterable list of authors with statistics
- Footer: Interactive controls help and search input
- Rust and Cargo: https://www.rust-lang.org/tools/install
- Git repository to analyze
- Clone the repository:
git clone https://github.com/amscotti/git_history_explorer.git
cd git_history_explorer
- Build and install:
cargo install --path .
- Run the application:
git_history_explorer
For development or testing:
- Clone the repository
- Install dependencies:
cargo build
- Run from source:
cargo run
git_history_explorer
git_history_explorer --path ~/projects/my-awesome-project
# Linux/macOS
git_history_explorer -p ~/.dotfiles
# Windows
git_history_explorer -p C:\Users\username\project
- Data Collection: Walks through Git commit history using
git2
crate - Data Processing: Uses Polars for efficient data aggregation and analysis
- Timeline Generation: Creates individual author timelines with actual commit dates
- Interactive UI: Renders using
ratatui
for responsive terminal interface - Real-time Updates: Handles user interactions with immediate visual feedback
- Optimized Processing: Uses Polars DataFrame operations for fast data analysis
- Memory Efficient: Streams commit data to minimize memory usage
- Large Repository Support: Tested with repositories containing millions of commits
- Fast Rendering: Efficient terminal UI updates for smooth interaction
- Rust 1.70+ (edition 2024)
- Git repository with commit history
- Terminal with UTF-8 support recommended
See LICENSE file for details.
Run the command in your terminal:
git_history_explorer [OPTIONS]
Options:
-p, --path <PATH>
: Specify the path to the Git repository (default is the current directory)
- Install Rust and Rustup: https://www.rust-lang.org/tools/install
- Clone this repository:
git clone https://github.com/amscotti/git_history_explorer.git
- Change to the project directory:
cd git_history_explorer
- Build and install the tool:
cargo install --path .
You can now run git_history_explorer
from your command line.