Skip to main content

gitintel


CI PyPI Python Version License Docs

GitIntel is a command-line repository intelligence tool that helps developers understand repository history, ownership, and risk hotspots.

Overview

GitIntel analyzes commit history, contributor contributions, and file ownership to help teams make informed maintenance and review decisions.

Key Features

  • Analyze Git history and contributor activity across a repository
  • Report file ownership by modifications, lines changed, and last touch
  • Identify hotspot files with risk and contributor concentration insights
  • Export reports as table, json, or markdown
  • Support local repositories and remote GitHub URLs
  • Provide a lightweight alias: gitit

Installation

From PyPI

For the recommended command-line installation, use pipx:

pipx install gitintel

This makes gitintel available globally without requiring you to activate a virtual environment.

Alternatively, install with pip:

python -m pip install gitintel

From source

git clone git@github.com:ThePhoenix77/GitIntel.git
cd GitIntel
python -m pip install -e .

Quick setup

For development, create a Python 3.11+ virtual environment and install the developer tools:

python -m venv .venv
source .venv/bin/activate
python -m pip install -e ".[dev]"

The convenience script is also available:

make setup

Quick Start

Analyze a repository:

gitintel analyze .

Use the alias:

gitit analyze .

No account or configuration is required. Run gitintel --help to see all commands, or pass a GitHub repository URL directly:

gitintel hotspots https://github.com/ThePhoenix77/GitIntel

CLI Reference

analyze

Analyze repository history and summary metrics.

gitintel analyze <path> [--format table|json|markdown]

Example:

gitintel analyze . --format markdown

ownership

Inspect file ownership and contributor activity.

gitintel ownership <path> [--all] [--file <path>] [--format table|json|markdown]

Examples:

gitintel ownership .
gitintel ownership . --all
gitintel ownership . --file src/gitintel/cli.py --format markdown

hotspots

Identify hotspot files that may need review.

gitintel hotspots <path> [--format table|json|markdown]

Example:

gitintel hotspots . --format json

Options

  • --format, -f — Output format: table, json, or markdown
  • --all — Include all ownership results instead of the default top files
  • --file — Filter ownership results to a specific file path
  • --quiet, -q — Suppress progress output

Development

Create and activate a local virtual environment:

python3 -m venv .venv
source .venv/bin/activate
python -m pip install -e .

Run tests:

python -m pytest -q

Project Structure

  • src/gitintel/cli.py — CLI entrypoint and command definitions
  • src/gitintel/git/ — Git repository access, diffs, and commit resolution
  • src/gitintel/analysis/ — analysis pipeline, ownership, and hotspot logic
  • src/gitintel/reports/ — terminal and markdown reporting

Contributing

Contributions are welcome. Please:

  1. Fork the repository
  2. Create a descriptive feature branch
  3. Open a pull request with tests and examples

Read the full contribution guidelines in CONTRIBUTING.md.

License

MIT License. See LICENSE for details.

Release files for gitintel 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gitintel 0.1.1
File Size Uploaded
gitintel-0.1.1.tar.gz 25.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for gitintel 0.1.1
File Interpreter ABI Platform
gitintel-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 47.2 kB

Release files / gitintel-0.1.1.tar.gz

Download URL gitintel-0.1.1.tar.gz
Size 25.7 kB
Tags Source
SHA-256 checksum
How to use checksums
94ed6a5aeacb28b0211c92e7c0852128b298e3e66840ab428c92bb0f774d656c
BLAKE2b-256 checksum
How to use checksums
3e7299616fc9302c52018a6a6a2abac861f78c56dec51b049e7e80c3675abe2e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.14

Release files / gitintel-0.1.1-py3-none-any.whl

Download URL gitintel-0.1.1-py3-none-any.whl
Size 21.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c1a97d5a53fbe97ccd436a3a99dfcfa6c557840d8e2db56755c76845f296049e
BLAKE2b-256 checksum
How to use checksums
760052e9b79f0a9cb6b65f47ef35b3560b1e4f37cdbd4223aaae495730a9ce0c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.14

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page