8000
Skip to content

JustinBenito/github-repo-contributions-graph

Repository files navigation

GitHub Contribution Graph Generator

An application that generates embeddable GitHub-style contribution graphs for any repository. Perfect for showcasing your project's activity in README files or documentation.

alt text

✨ Features

  • Generate GitHub-style contribution graphs for any public repository
  • View detailed contribution statistics and metrics
  • Real-time data fetching from GitHub's API
  • 🖼️ Download contribution graphs as PNG images
  • 🔗 Generate shareable links for your contribution graphs

🚀 Getting Started

Prerequisites

  • ReactJS
  • A GitHub account (for API access)
  • Supabase account (for image storage)

Installation

  1. Fork the repository and clone yours:
git clone https://github.com/your-name/github-repo-contributions-graph
cd github-contributions
  1. Install dependencies:
npm install
# or
yarn install
  1. Create a .env file in the root directory and add your environment variables:
VITE_SUPABASE_URL=your_supabase_url
VITE_SUPABASE_ANON_KEY=your_supabase_anon_key
  1. Start the development server:
npm run dev
# or
yarn dev

The application will be available at http://localhost:5173

🛠️ Built With

📝 Usage

  1. Enter a GitHub repository URL in the format: https://github.com/username/repository
  2. Click "Generate Graph"
  3. View the contribution statistics and graph
  4. Download the graph as a PNG image or copy the shareable link

🔧 Configuration

Supabase Setup

  1. Create a new Supabase project
  2. Create a new table called contribution_graphs with the following schema:
create table contribution_graphs (
  id text primary key,
  owner text not null,
  repo text not null,
  repository_data jsonb,
  contribution_data jsonb,
  contributors_count integer,
  updated_at timestamp with time zone
);
  1. Add your Supabase URL and anon key to the .env file

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

📄 License

This project is licensed under the GPL3 License - see the LICENSE file for details.

About

Get a contributors graph for individual repositories to display the commit activity of your repos

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0