Skip to content

nalaka/gitrpt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gitrpt: Git Report

About

gitrpt generates a report of commit activity and individual contributions from your team members across locally cloned Git repositories.

Installation

TODO

Usage

Navigate to your project folder and run gitrpt:

cd foobar
gitrpt

If foobar is a Git repository, gitrpt reads all commits and generates a report at foobar/gitrpt-<timestamp>.pdf. If foobar is not a Git repository, gitrpt checks all top-level directories within it and generates a combined report.

The --format option can be used to generate the report in different formats.

gitrpt --format=pdf
gitrpt --format=md
gitrpt --format=csv

The default report file format is pdf.

The --period option can be used to limit the reporting period.

gitrpt --period=all
gitrpt --period=year
gitrpt --period=month
gitrpt --period=week
gitrpt --period=yesterday
gitrpt --period=today

The default reporting period is all.

Examples

# PDF report of team work done yesterday across all repositories 
gitrpt --all --format=pdf --period=yesterday

For power users

Using a gitrpt configuration file

Report generation can be configured with a .gitrpt.ini file in your home directory. Generate a template with:

gitrpt --gen-config

If a .gitrpt.ini file already exists in your home directory, it will not be overwritten.

[report]
title = FooBar Team Activity Report
format = pdf

[repos]
frontend = ~/foobar/frontend
backend = ~/foobar/backend
automations = ~/foobar/automations

[ident:alice_kim]
name = Alice Kim
alias = Alice K <alice.kim@foobar.com>, alicek <alice@gmail.com>

[ident:sam_porter]
name = Samuel Porter
alias = Sam <saporter789m@yahoo.com>, Porter S. <samp@foobar.org>

Using the ident sections, different name and email pairs in commits can be mapped to the same Identity (a single real-world person).

The --list-repos and --list-authors options respectively print "all the repositories" that gitrpt has previously scanned and "all the commit authors" encountered across those repositories.

gitrpt --list-repos
gitrpt --list-authors

To generate a combined report from the list of repositories configured in your ~/.gitrpt.ini file, use the --all option:

gitrpt --all

Deleting the gitrpt database

The gitrpt database stores commit metadata of all the repositories it has generated reports against. It is a single file SQlite database stored in your home directory as .gitrpt.db. When a gitrpt command is not running, you can safely delete this file.

About

Local Git analytics CLI | Transform multi-repo commit data into a cohesive team activity report.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages