Skip to content

xxspell/metrics-generator

Repository files navigation

GitHub Metrics Generator

xxspell GitHub Profile README

A Python tool that generates GitHub metrics (stats, languages, Last.fm integration) and commits them to a repository. Can be used as a GitHub Action or run locally.

Features

  • Generates GitHub statistics (repos, stars, commits, followers, lines of code)
  • Supports language usage visualization
  • Integrates with Last.fm for music stats
  • Outputs SVG files for GitHub profile READMEs

Installation

uv sync

Usage

As GitHub Action

Add to your workflow:

- uses: xxspell/metrics-generator@v1
  with:
    target_repository: 'your-username/your-repo'
    access_token: ${{ secrets.GITHUB_TOKEN }}
    user_name: 'your-username'
    lastfm_token: ${{ secrets.LASTFM_TOKEN }}
    lastfm_user: 'your-lastfm-username'

See example-action-usage.yml for full configuration.

Local Usage

uv run a.py

Set environment variables as needed (ACCESS_TOKEN, USER_NAME, etc.).

Inputs

  • target_repository: Repository to commit to (owner/repo)
  • access_token: GitHub token
  • user_name: GitHub username
  • lastfm_token: Last.fm API token
  • lastfm_user: Last.fm username
  • proxy: Optional proxy
  • excluded_repos: Comma-separated repos to exclude
  • excluded_languages: Languages to exclude from stats

About

Generate GitHub metrics and commit them to repository

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages