https://github.com/castrozan/private-gitlab-heatmap-exporter

daily exports a svg heatmap for private gitlab instances

https://github.com/castrozan/private-gitlab-heatmap-exporter

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.3%) to scientific vocabulary
Last synced: 6 months ago · JSON representation

Repository

daily exports a svg heatmap for private gitlab instances

Basic Info
  • Host: GitHub
  • Owner: Castrozan
  • Language: Nix
  • Default Branch: master
  • Homepage:
  • Size: 32.2 KB
Statistics
  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created 8 months ago · Last pushed 7 months ago
Metadata Files
Readme

README.md

GitLab Contribution Graph Generator

This project automatically generates a GitHub-style contribution graph from a private GitLab instance and displays it in this README.

My GitLab Contributions

GitLab Contributions

How It Works

A GitHub Action runs daily, executing a Python script that fetches your GitLab contribution events from the last year. It then generates an SVG image mimicking the GitHub contribution graph and commits the updated SVG back to this repository.

Setup

Repository Secrets

To use this action, configure the following secrets in your GitHub repository under Settings > Secrets and variables > Actions:

  • GITLAB_URL: The base URL of your GitLab instance (e.g., https://gitlab.com).
  • GITLAB_TOKEN: A GitLab Personal Access Token with read_user scope.
  • RUNNER_CHECK_TOKEN: A fine-grained personal GitHub access token with repository administration read permissions to check runner status (see here for more information).

Self-hosted Runner

If your GitLab instance is on a private network or requires a VPN, the default GitHub-hosted runner will not be able to access it. You must use a self-hosted runner that is configured on a machine within that network - it can be your work laptop, a home server, etc.

The workflow file is already configured to use a self-hosted runner.

Self-hosted Runner Status Check

The workflow includes an automatic runner status check that verifies if your self-hosted runner is online before executing the build.

Local Development

To run the script locally for testing:

  1. Create a nix shell: bash nix-shell

  2. Set environment variables: bash export GITLAB_URL="<your_gitlab_instance_url>" export GITLAB_TOKEN="<your_gitlab_pat>" export RUNNER_CHECK_TOKEN="<your_fine_grained_token>"

  3. Run the script: bash python .github/scripts/gitlab_heatmap.py

Owner

  • Name: Lucas Zanoni
  • Login: Castrozan
  • Kind: user

GitHub Events

Total
  • Watch event: 1
  • Push event: 32
Last Year
  • Watch event: 1
  • Push event: 32

Dependencies

.github/workflows/update-graph.yml actions
  • actions/checkout v4 composite
  • actions/setup-python v5 composite