Metadata-Version: 2.4
Name: git-archaeologist
Version: 1.0.1
Summary: A CLI tool for analyzing Git repository history
Requires-Python: >=3.10
Description-Content-Type: text/markdown
Requires-Dist: GitPython

# Git Archaeologist
A python CLI tool for quickly analyzing and exploring the history of Git repositories.

# Problem
Understanding a Git repository's history can be very time consuming when done manually. Git provides a huge amount of information, but finding useful patterns-such as the repository's lifespan, periods of inactivity, most active months, contributors, and commit history-often requires running multiple commands and manually interpreting the results.

__Git Archaeologist__ simplifies this process by collecting important repository statistics and presenting them in a clear human-readable format or a JSON format for developers.

# Features

- Repository summary
    -  Total commits
    -  Number of contributors
    -  Number of lines changed
    -  Total insertions
    -  Total deletions
    -  Total lines changed

- Timeline analysis
    -  First commit
    -  Latest commit
    -  Repo Lifespan

- Activity analysis
    -  Most active month
    -  Number of commits during the most active month
    -  Longest period of inactivity
    -  Commits marking the begining and end of the longest gap

- Commit History
    -  Commit SHA1
    -  Commit data
    -  Commit message
    -  Author

- JSON output
    -  Machine-readable repository statistics
    -  Useful for scripts, automation and other apps

# Installation

Clone the repository:

``` bash
$ git clone https://github.com/omarelhalaby76-coder/git-archaeologist
$ cd git-archaeologist
```
Install the dependencies:
``` bash
$ pip install -r requirments.txt
```
Or install the project directly:
``` bash
$ pip install git-archaeologist
```

# Usage
where . is the path to the repository
show a summary:
``` bash
$ git-archaeologist . --summary
```
show history:
``` bash
$ git-archaeologist . --history
```
show activity:
```bash
$ git-archaeologist . --activity
```
show JSON:
```bash
$ git-archaeologist . --json
```
show timeline:
```bash
$ git-archaeologist . --timeline
```
show an overview:
``` bash
$ git-archaeologist .
```

show version:
```bash
$ git-archaeologist --version
```
help:
``` bash
$ git-archaeologist --help
```
# requirments
- python 3.x
- git
- gitpython

# how it works
Git Archaeologist uses GitPython to access the repository and analyze its commit history.
The analyzer iterates through the repository's commits and calculates statistics including:
Repository lifespan
Contributors
Files changed
Insertions and deletions
Monthly commit activity
Longest gap between commits
Complete commit history
The CLI then presents the collected information in different formats depending on the selected option.
