1 unstable release
new 0.1.0 | May 22, 2025 |
---|
#673 in Development tools
15KB
206 lines
Githeat โ Git Contribution Heatmap
githeat
is a terminal-based tool that visualizes Git commit activity by file or author using a dynamic TUI interface. It's written in Rust and powered by git2
, ratatui
, and clap
.
๐ Features
- ๐ฅ Heatmap of file or author commit activity
- ๐
Filter by time (
--since
,--since-date
) - ๐งโ๐ป Group by author or file
- ๐งน Sort output by commit count (
--sort
) - ๐ฏ Filter by path or extension (
--path
,--ext
) - โฌ๏ธ Limit to top N entries (
--top
) - ๐ค Export to JSON or Markdown (
--export
)
๐งช Commands
๐น Basic Usage
githeat # Default file heatmap
githeat --by-author # Author contribution heatmap
๐น Time Filtering
githeat --since 30 # Last 30 days
githeat --since-date 2025-01-01 # Since specific date
๐น Sorting & Limiting
githeat --top 10 # Top 10 files or authors
githeat --sort asc # Sort by ascending commit count
githeat --sort desc # Sort by descending (default)
๐น Filtering by File
githeat --ext rs # Only .rs files
githeat --path src # Only files in src/
๐น Exporting
githeat --export json # Export to githeat_export.json
githeat --export md # Export to githeat_export.md
๐น Combine Filters
githeat --by-author --since-date 2025-01-01
githeat --path src --ext rs --top 5 --sort desc --export json
๐ฅ๏ธ Local Usage (Development Mode)
From your project folder:
cargo run -- --by-author
cargo run -- --path src --top 5 --sort desc
๐ฆ Make githeat
a Global Command
๐ง Install it globally
cargo install --path .
This installs the binary into:
C:\Users\<your_username>\.cargo\bin
๐งญ Add to PATH (Permanent)
- Open Environment Variables in Windows
- Under User Variables, edit
Path
- Add this new entry:
C:\Users\<your_username>\.cargo\bin
- Click OK and restart PowerShell
โ Now use from anywhere:
githeat --since 14 --top 5
๐ง Dev Notes
- Built with Rust 2021
- Depends on:
git2
,ratatui
,crossterm
,clap
,serde
,serde_json
- TUI is rendered via
ratatui
git2
parses repo history and diffs
๐ License
MIT โ ยฉ 2025 Andrew Alvarez
Contributions, issues, and PRs welcome!
Made with โค๏ธ for developers who ship.
Dependencies
~15โ23MB
~364K SLoC