11# GitHub Trending CLI
22
3- ``` bash
4-
5- _ _ _ _ _ _ _ _ _
6- (_) | | | | | | | | (_) | (_)
7- __ _ _| | _| | __ _ _| | __ ______| | _ _ __ ___ _ __ __| | _ _ __ __ _ ______ ___| | _
8- / _` | | __| ' _ \| | | | ' _ \_ _____| __| ' __/ _ \ ' _ \ / _` | | ' _ \ / _` |______/ __| | |
9- | (_| | | |_| | | | |_| | |_) | | |_| | | __/ | | | (_| | | | | | (_| | | (__| | |
10- \__, |_|\__|_| |_|\__,_|_.__/ \__|_| \___|_| |_|\__,_|_|_| |_|\__, | \___|_|_|
11- __/ | __/ |
12- |___/ |___/
13- ```
3+ We like browsing GitHub's trending page, so we made a CLI version.
144
15- Browse GitHub' s trending repositories from your terminal with daily star counts and README viewing.
5+ ![ GitHub Trending CLI Screenshot ] ( github-trending-screenshot.png )
166
177[ ![ Python] ( https://img.shields.io/badge/python-3.7+-blue.svg )] ( https://www.python.org/downloads/ )
188[ ![ License: MIT] ( https://img.shields.io/badge/License-MIT-yellow.svg )] ( https://opensource.org/licenses/MIT )
199
20- # # Features
10+ ## What it does
2111
22- - View trending repositories with real-time daily star counts
23- - Support for daily, weekly, and monthly time ranges
24- - Interactive README viewing with syntax highlighting
25- - Language indicators and trending level indicators
26- - Clean terminal interface using Rich
12+ - Shows trending repositories with daily star counts
13+ - Supports daily, weekly, and monthly views
14+ - Click on any repo to read its README
15+ - Simple terminal interface
2716
2817## Installation
2918
@@ -32,7 +21,7 @@ git clone https://github.com/your-username/github-trending-cli.git
3221cd github-trending-cli
3322
3423python3 -m venv venv
35- source venv/bin/activate # On Windows: venv\Scripts\activate
24+ source venv/bin/activate
3625
3726pip install -r requirements.txt
3827pip install -e .
@@ -41,64 +30,27 @@ pip install -e .
4130## Usage
4231
4332``` bash
44- # View today's trending repositories
45- github-trending
46-
47- # View weekly trending
48- github-trending --range weekly
49-
50- # View monthly trending
51- github-trending -r monthly
33+ github-trending # today's trending
34+ github-trending --range weekly # this week
35+ github-trending -r monthly # this month
5236```
5337
54- # # Example Output
38+ Enter a repo number to read its README, or press Enter to see more repos.
5539
56- ```
57- 🚀 GitHub Trending Repositories - Daily 📅
58-
59- 1 . microsoft/TypeScript 🔷 ⭐95,234 🔥+1,234
60- TypeScript is a superset of JavaScript that compiles to clean JavaScript
61-
62- 2 . facebook/react ⚛️ ⭐201,456 🚀+567
63- A declarative, efficient, and flexible JavaScript library
64-
65- 3 . python/cpython 🐍 ⭐45,123 📈+89
66- The Python programming language
67-
68- Enter repo number (1-3), Enter for more, 'q' to quit:
69- ```
70-
71- Trending indicators: 🔥 100+ daily stars, 🚀 50+ daily stars, 📈 10+ daily stars
72-
73- ## Architecture
40+ ## How it works
7441
75- - `scraper.py` - Fetches and parses GitHub's trending page
76- - `display.py` - Terminal UI using Rich library
77- - `cli.py` - Command-line interface and argument parsing
42+ Scrapes GitHub's trending page and displays it in your terminal. That's it.
7843
79- ## Dependencies
44+ - ` scraper.py ` - Gets the trending page HTML and parses it
45+ - ` display.py ` - Shows the data nicely in terminal
46+ - ` cli.py ` - Handles the command line stuff
8047
81- - `requests` - HTTP requests
82- - `beautifulsoup4` - HTML parsing
83- - `rich` - Terminal formatting
84- - `lxml` - XML/HTML processing
48+ Uses ` requests ` , ` beautifulsoup4 ` , ` rich ` , and ` lxml ` .
8549
8650## Contributing
8751
88- 1. Fork the repository
89- 2. Create a feature branch: `git checkout -b feature-name`
90- 3. Make your changes
91- 4. Run tests if available
92- 5. Submit a pull request
93-
94- ## Troubleshooting
95-
96- | Issue | Solution |
97- |-------|----------|
98- | `ModuleNotFoundError` | Run `pip install -e .` in project directory |
99- | Connection errors | Check internet connection |
100- | Empty results | GitHub may be rate limiting, wait a few minutes |
52+ Fork it, make changes, send a PR.
10153
10254## License
10355
104- MIT License - see [LICENSE](LICENSE) file for details.
56+ MIT
0 commit comments