Skip to content

๐Ÿš A lightweight shell script to analyze and visualize the daily star statistics of GitHub repositories.

License

Notifications You must be signed in to change notification settings

elliotxx/github-star

Repository files navigation

github-star

GitHub Star Statistics

๐Ÿš A lightweight shell script to analyze and visualize the daily star statistics of GitHub repositories.

English | ็ฎ€ไฝ“ไธญๆ–‡

github-star-demo.mp4

โœจ Features

  • ๐Ÿ“Š Track daily star counts for any GitHub repository
  • ๐Ÿ“ˆ Generate statistics and trends
  • ๐Ÿ’ป Easy-to-use command line interface
  • ๐ŸŽจ Colorful output for better visualization

๐Ÿš€ Prerequisites

โš ๏ธ Important Notes:

  • Currently only supports macOS
  • Requires GitHub CLI authentication
  • Internet connection required for API access

Required tools:

  • ๐Ÿ”ง macOS operating system
  • ๐Ÿ›  GitHub CLI (gh)
  • ๐Ÿ” jq command line tool
  • ๐Ÿš Bash shell environment

๐Ÿ”ง Installation

  1. Install GitHub CLI:
brew install gh
  1. Install jq:
brew install jq
  1. Login to GitHub:
gh auth login

๐Ÿ“– Usage

There are several ways to use this tool:

1. ๐ŸŒ Direct Usage (No Download Required)

# Using curl
curl -s https://raw.githubusercontent.com/elliotxx/github-star/main/github-star.sh | bash -s -- KusionStack/karpor

# Using wget
wget -qO- https://raw.githubusercontent.com/elliotxx/github-star/main/github-star.sh | bash -s -- KusionStack/karpor

# Pipe directly to bash
bash <(curl -s https://raw.githubusercontent.com/elliotxx/github-star/main/github-star.sh) KusionStack/karpor

2. ๐Ÿ’พ Local Installation

# Download the script
curl -O https://raw.githubusercontent.com/elliotxx/github-star/main/github-star.sh

# Make the script executable
chmod +x github-star.sh

# Run the script
./github-star.sh owner/repo

# Example usage
./github-star.sh KusionStack/karpor

3. โšก๏ธ Alias Setup

Add one of these aliases to your shell configuration file (~/.bashrc, ~/.zshrc, etc.):

# Basic alias
alias ghstar='/path/to/github-star.sh'

# Direct from GitHub (no local file needed)
alias ghstar='curl -s https://raw.githubusercontent.com/elliotxx/github-star/main/github-star.sh | bash -s --'

# Example usage with alias
ghstar KusionStack/karpor

๐Ÿ“Š Output Format

The script outputs data in the following format:

  • ๐Ÿ“… Date: The date when stars were received
  • โญ๏ธ Stars: Number of stars received on that date
  • ๐Ÿ“ˆ Total: Cumulative total of stars
  • ๐Ÿ”„ Trend: Visual indicator of star growth

โš–๏ธ License

MIT License

About

๐Ÿš A lightweight shell script to analyze and visualize the daily star statistics of GitHub repositories.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages