Skip to main content

Generate a list of contributors automatically from git data

Project description

contributors-txt

PyPI version PyPI - Python Version PyPI - License

Generate a list of contributors automatically from git data.

Install

pip install contributors-txt

Usage

Run inside a git repository. Without an alias file, contributors are listed straight from git shortlog:

contributors-txt -o CONTRIBUTORS.txt

Pass an alias file to merge multiple emails under one name and assign teams:

contributors-txt -a aliases.json -o CONTRIBUTORS.txt

Add --no-bots to filter out GitHub Apps (dependabot[bot], pre-commit-ci[bot], github-actions[bot], Copilot, Claude, …):

contributors-txt --no-bots -a aliases.json -o CONTRIBUTORS.txt

If the output file already exists it is updated in place: missing emails are added and new contributors are inserted in commit-count order, preserving any manual edits.

Alias file

{
  "pierre.sassoulas@gmail.com": {
    "mails": ["pierre.sassoulas@gmail.com", "pierre.sassoulas@elum-energy.com"],
    "name": "Pierre Sassoulas",
    "team": "Maintainers"
  }
}

Two helpers ship alongside the main command:

  • contributors-txt-normalize-configuration -a aliases.json rewrites an alias file in the canonical sorted form.
  • contributors-txt-extract-comment <CONTRIBUTORS.txt> -a aliases.json pulls free-text comments from an existing CONTRIBUTORS file back into the alias file.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

contributors_txt-1.0.2.tar.gz (42.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

contributors_txt-1.0.2-py3-none-any.whl (13.6 kB view details)

Uploaded Python 3

File details

Details for the file contributors_txt-1.0.2.tar.gz.

File metadata

  • Download URL: contributors_txt-1.0.2.tar.gz
  • Upload date:
  • Size: 42.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.25

File hashes

Hashes for contributors_txt-1.0.2.tar.gz
Algorithm Hash digest
SHA256 afad582bc1c6a7c9d151e54773ef94daae305e0d9a1fac7aa56588b37cf4584b
MD5 43443ec73bb55733f1eb1d67ea4b707c
BLAKE2b-256 15596ccd5fd58df704a719c01f501e5c02b042c7031719e301e40403098b0d02

See more details on using hashes here.

File details

Details for the file contributors_txt-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for contributors_txt-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1049dae88d5393964d44266cb1f21dcef69569ca34d9c8570a19d85af500bc9e
MD5 dec81ba1acf009d0fd3133151b96d3d0
BLAKE2b-256 67b7005c04348666f95370694872413f5a2bf277d6565060712f46924441a73c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page