Skip to content

PankajKumardev/gitstory-2025

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

35 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🎬 GitStory 2025

Your Year in Code β€” Cinematic Wrapped

Next.js React TypeScript Tailwind Framer Motion NextAuth

Transform your GitHub & GitLab contributions into a stunning, Instagram Stories-style cinematic experience.

🌐 Live Demo β€’ ✨ Features β€’ ⚑ Quick Start β€’ πŸ› οΈ Tech Stack


✨ Features

Feature Description
πŸŽ₯ Cinematic Experience 11 beautifully animated slides with Instagram Stories-like navigation
πŸ“Š Live GitHub & GitLab Data Real-time stats fetched from GitHub/GitLab API β€” commits, PRs, issues, reviews
πŸ” OAuth Authentication One-click login with GitHub or GitLab
πŸŒ“ Dark/Light Theme Toggle between themes on main page and slides
🧬 Smart Archetypes AI-determined coding personas: Night Owl, Weekend Warrior, Grid Painter, and more
πŸ“ˆ Velocity Charts Animated contribution charts powered by Recharts
πŸ—“οΈ Contribution Grid Visual heatmap of your 2025 coding activity
πŸ† Top 5 Repositories Showcase your best projects with smart ranking
🎨 Language Breakdown Beautiful visualization of your tech stack (55+ languages!)
πŸ“± Mobile-First Touch gestures: tap left/right to navigate, hold to pause
πŸ–ΌοΈ Poster Export Download a shareable movie-poster style summary
πŸ”— Social Sharing Share to Twitter, LinkedIn, Reddit, WhatsApp with one click
🎊 Confetti Celebration End your story with style
πŸ” SEO Optimized Built with Next.js for better search engine visibility

πŸ†• What's New (v4.0)

πŸ” OAuth Authentication

  • GitHub OAuth β€” One-click login, no token copying needed
  • GitLab OAuth β€” Full GitLab support with OAuth authentication
  • Private repos & org repos automatically included when authenticated

πŸŒ“ Theme Toggle

  • Dark/Light Mode β€” Toggle on main page and within slide presentation
  • Play/Pause Controls β€” On-screen buttons during story playback
  • Theme-aware slides β€” All 11 slides adapt to your preferred theme

πŸ”— Social Sharing

  • Share Button β€” On the final poster slide
  • Multiple platforms β€” Twitter, LinkedIn, Reddit, WhatsApp
  • Copy Link β€” With toast notification
  • Pre-written share text β€” Automatically includes your stats

🦊 GitLab Support

  • Full GitLab API integration β€” Same cinematic experience for GitLab users
  • OAuth authentication β€” Login with GitLab account
  • Project stats β€” Commits, merge requests, issues from GitLab

πŸš€ Previous Updates

Next.js Migration (v3.0)

  • Migrated from Vite to Next.js 16 for better SEO and performance
  • Server-side metadata for improved social sharing (Twitter, Facebook, LinkedIn)
  • Optimized fonts with next/font/google for better performance
  • Dynamic sitemap generation for search engines

Optimized API (v2.0)

  • With Token: Only 4 API calls (GraphQL bundles contributions + PR/Issue/Review counts!)
  • Without Token: 7 API calls (REST fallback)
  • 43% fewer API calls when authenticated!

Smart Repository Scoring

Projects are now ranked using 12 factors instead of just stars:

  • ⭐ Stars & Forks (logarithmic scale)
  • πŸ“… Recent activity in 2025 (time-decay bonus)
  • ✨ Original work (not forks)
  • πŸ“ Description & Topics
  • πŸ’» Primary language
  • πŸ“¦ Repository size
  • πŸ› Open issues (activity indicator)
  • πŸ†• Created in 2025 bonus
  • πŸ‘€ Watchers
  • πŸ“¦ Archived penalty

🎬 Slides

Experience your year through 11 cinematic slides:

# Slide What It Shows
1 Title Your username & avatar with dramatic reveal
2 Velocity Animated area chart of daily commits
3 Grid Full-year contribution heatmap
4 Composition Breakdown: Commits vs PRs vs Issues vs Reviews
5 Routine Your busiest day of the week
6 Productivity Peak coding hours & time-of-day persona
7 Community Followers, stars, and repo count
8 Languages Top 3 programming languages
9 Top 5 Repos Your best repositories ranked by score
10 Top Repo Spotlight on your #1 repository
11 Poster 🎬 Downloadable movie poster + Share buttons

🧬 Archetypes

Based on your behavior patterns, you'll be assigned one of these personas:

Archetype Criteria
πŸ”€ The Pull Request Pro Opens many PRs (>20% of activity)
πŸ‘€ The Reviewer Frequent code reviewer (>10% of activity)
πŸŒ™ The Night Owl Peak activity after 10 PM
πŸŒ… The Early Bird Peak activity before noon
πŸ—“οΈ The Weekend Warrior >35% commits on weekends
🎨 The Grid Painter 1200+ commits (green squares everywhere!)
⚑ The Consistent 400+ commits, steady contributor
πŸ“‹ The Planner High issue-to-commit ratio
⭐ The Community Star 500+ followers or 1000+ total stars
πŸ”§ The Tinkerer Default β€” you're exploring!

⚑ Quick Start

# Clone the repository
git clone https://github.com/PankajKumardev/gitstory-2025.git
cd gitstory-2025

# Install dependencies
npm install

# Set up environment variables
cp .env.example .env.local
# Edit .env.local with your OAuth credentials

# Start development server
npm run dev

Open http://localhost:3000 and enter any GitHub username!

πŸ’‘ Tip: Type demo to see a full experience with mock data.


πŸ” Authentication

OAuth Login (Recommended)

Click GitHub or GitLab button on the home page for one-click authentication.

Environment Variables

# NextAuth Configuration
NEXTAUTH_URL=https://gitstory.pankajk.tech
NEXTAUTH_SECRET=your-secret-key

# GitHub OAuth (https://github.com/settings/developers)
GITHUB_CLIENT_ID=your-github-client-id
GITHUB_CLIENT_SECRET=your-github-client-secret

# GitLab OAuth (https://gitlab.com/-/user_settings/applications)
GITLAB_CLIENT_ID=your-gitlab-client-id
GITLAB_CLIENT_SECRET=your-gitlab-client-secret

OAuth Callback URLs

Provider Callback URL
GitHub https://yourdomain.com/api/auth/callback/github
GitLab https://yourdomain.com/api/auth/callback/gitlab

GitLab Scopes Required

  • read_user β€” Profile info
  • read_api β€” API access
  • read_repository β€” Repository access

Benefits with OAuth

Feature Without OAuth With OAuth
Rate Limit 60/hour 5000/hour
Private Repos ❌ βœ…
Org Repos ❌ βœ…
Private Contributions ❌ βœ…

πŸ› οΈ Tech Stack

Technology Purpose
Next.js 16 React framework with App Router for SEO & performance
React 19 UI Components with latest features
NextAuth.js OAuth authentication for GitHub & GitLab
TypeScript Type-safe development
Tailwind CSS 4 Utility-first styling with @theme config
Framer Motion Buttery-smooth animations
Recharts Beautiful, responsive charts
Lucide React Consistent icon system
html-to-image Poster PNG export
canvas-confetti Celebration effects 🎊
Vercel Analytics Privacy-friendly analytics

πŸ“± Controls

On-Screen Controls

Button Effect
⏸️ Pause Pause slide timer
β˜€οΈ/πŸŒ™ Theme Toggle dark/light mode
βœ• Close Exit story
πŸ“€ Share Share to social (poster slide)

Touch Gestures (Mobile)

Action Effect
Tap right 2/3 Next slide
Tap left 1/3 Previous slide
Hold anywhere Pause timer
Release Resume timer

Keyboard Controls (Desktop)

Key Effect
β†’ or D Next slide
← or A Previous slide
Space Pause/Resume
Escape Exit story

πŸ—οΈ Project Structure

gitstory-2025/
β”œβ”€β”€ app/
β”‚   β”œβ”€β”€ api/auth/[...nextauth]/  # NextAuth API route
β”‚   β”œβ”€β”€ layout.tsx               # Root layout with providers
β”‚   β”œβ”€β”€ page.tsx                 # Main page with OAuth
β”‚   β”œβ”€β”€ globals.css              # Tailwind + custom styles
β”‚   └── sitemap.ts               # Dynamic sitemap
β”œβ”€β”€ components/
β”‚   β”œβ”€β”€ providers/
β”‚   β”‚   └── SessionProvider.tsx  # NextAuth session wrapper
β”‚   β”œβ”€β”€ StoryContainer.tsx       # Slide navigation & controls
β”‚   β”œβ”€β”€ SlideLayout.tsx          # Theme-aware slide wrapper
β”‚   └── slides/                  # 11 slide components
β”œβ”€β”€ context/
β”‚   └── ThemeContext.tsx         # Dark/light theme context
β”œβ”€β”€ lib/
β”‚   └── auth.ts                  # NextAuth configuration
β”œβ”€β”€ services/
β”‚   β”œβ”€β”€ githubService.ts         # GitHub API integration
β”‚   β”œβ”€β”€ gitlabService.ts         # GitLab API integration
β”‚   └── scoringAlgorithms.ts     # Scoring logic
β”œβ”€β”€ types.ts                     # TypeScript interfaces
└── constants.ts                 # Mock data & configuration

πŸš€ Build & Deploy

# Production build
npm run build

# Start production server
npm start

Deploy to any platform that supports Next.js:

  • Vercel (recommended - zero config)
  • Netlify
  • Railway
  • Cloudflare Pages

Vercel Environment Variables

Add these in your Vercel project settings:

  • NEXTAUTH_URL
  • NEXTAUTH_SECRET
  • GITHUB_CLIENT_ID
  • GITHUB_CLIENT_SECRET
  • GITLAB_CLIENT_ID
  • GITLAB_CLIENT_SECRET

πŸ“„ License

MIT License with Attribution β€” see LICENSE for full text.

⚠️ Attribution Required

If you use, modify, or build upon this project, you MUST:

  1. βœ… Credit the original author β€” Include "Based on GitStory by Pankaj Kumar" in your README
  2. βœ… Link to the original repo β€” https://github.com/PankajKumardev/gitstory-2025
  3. ❌ Do NOT claim original authorship β€” This includes Product Hunt, social media, or any other platform
  4. ❌ Do NOT remove copyright notices β€” Keep the license file and copyright comments

Why This Matters

This project took significant effort to create. If you found it useful, please:

  • ⭐ Star this repo
  • πŸ”— Credit the original when sharing
  • 🐦 Tag @pankajkumar_dev when posting about it

Copyright Β© 2024-2025 Pankaj Kumar


Made with πŸ’œ for developers who ship

Star ⭐ this repo if you found it useful!

🌐 Try GitStory 2025 | 🐦 Twitter

About

GitStory 2025 - Your Year in Code GitHub Wrapped

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors