https://github.com/wewebunnyx/le-termuddit
A Reddit CLI Feeder / Terminal Browser Client
https://github.com/wewebunnyx/le-termuddit
api bash chafa cli curl gnu-linux jq linux oauth2 operating-systems reddit terminal
Last synced: 4 months ago
JSON representation
A Reddit CLI Feeder / Terminal Browser Client
- Host: GitHub
- URL: https://github.com/wewebunnyx/le-termuddit
- Owner: WeWeBunnyX
- License: gpl-3.0
- Created: 2025-04-26T08:29:05.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-09-19T18:30:17.000Z (4 months ago)
- Last Synced: 2025-09-19T20:58:56.268Z (4 months ago)
- Topics: api, bash, chafa, cli, curl, gnu-linux, jq, linux, oauth2, operating-systems, reddit, terminal
- Language: Shell
- Homepage:
- Size: 757 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# Termuddit - Reddit CLI Client
A command-line interface Reddit client written in Bash that lets you browse Reddit from your terminal with a clean, colorful interface.




## Features
- 🎨 Colorful and clean terminal interface
- 👀 Browse subreddits and view posts
- 🖼️ View images as ASCII art in terminal
- 💬 View nested comments with proper threading
- 🔄 Refresh posts and comments
- 🎯 Load more comments on demand
- 🔒 Secure credential management
- 🚀 Fast and lightweight
## Prerequisites
- Bash 4.0+
- `curl`
- `jq` (JSON processor)
- `figlet` (for splash screen)
- `chafa` (for ASCII art images)
- Reddit API credentials
## Installation
1. Clone the repository:
```bash
git clone https://github.com/WeWeBunnyX/Le-Termuddit.git
cd Le-Termuddit
```
2. Make scripts executable:
```bash
chmod +x *.sh
```
3. Install dependencies:
### Ubuntu/Debian
```bash
sudo apt install jq curl figlet chafa
```
### Fedora/RHEL
```bash
sudo dnf install jq curl figlet chafa
```
### Arch Linux
```bash
sudo pacman -S jq curl figlet chafa
```
### macOS (using Homebrew)
```bash
brew install jq curl figlet chafa
```
### Using Package Manager Alternatives
| Distribution | Package Manager | Command |
|-------------|----------------|---------|
| OpenSUSE | zypper | `sudo zypper install jq curl figlet chafa` |
| Alpine | apk | `sudo apk add jq curl figlet chafa` |
| Gentoo | emerge | `sudo emerge jq curl figlet chafa` |
| Void Linux | xbps | `sudo xbps-install -S jq curl figlet chafa` |
## Setup
1. Create a Reddit App:
- Go to [https://www.reddit.com/prefs/apps](https://www.reddit.com/prefs/apps)
- Click "Create App" or "Create Another App"
- 
- Fill in the required information and click 'create app' (name and description field can be anything you like, select script as the type and redirect uri as shown below)

- Note your Client ID and Client Secret

2. Run Termuddit:
```bash
./termuddit.sh
```
3. Enter your Reddit API credentials when prompted

## Usage
**1**. Start the application:
```bash
./termuddit.sh --noimg
```
Or just use ```./termuddit.sh``` to render images along with the post (without --noimg flag). The images are converted to ASCII art and may not be in full quality/resolution due to terminal limitations
**2**. Enter a subreddit name when prompted (e.g., "linux", "programming")
**3**. Choose number of posts to fetch
### Navigation
- Enter post number to view its comments
- `r` - Refresh posts
- `q` - Return to main menu
### Comment View
- `m` - Load more comments
- `r` - Refresh current comments
- `q` - Return to posts view
### Image Display (use ```-noimg``` flag to disable)
Images in posts are automatically converted to ASCII art using `chafa`. The quality depends on:
- Terminal color support (256 colors recommended)
- Terminal font (Unicode support required)
- Terminal window size
## Project Structure
```
termuddit/
├── termuddit.sh # Main script
├── authenticate.sh # Reddit API authentication
├── get_posts.sh # Post fetching and display
├── get_comments.sh # Comment fetching and display
└── splash.sh # Splash screen
```
## Security
- Credentials are stored locally in `credentials.txt`
- Access token is stored in `access_token.txt`
- Both files are git-ignored
## Contributing
Contributions are welcome, you may open a pull request or submit an issue.
## License
This project is licensed under the GNU General Public License v3.0 - see the [LICENSE](LICENSE) file for details.
## Acknowledgments/References
- [Reddit API Documentation](https://www.reddit.com/dev/api/)
- [Reddit OAuth2 Guide](https://github.com/reddit-archive/reddit/wiki/OAuth2)
- [JQ Manual](https://stedolan.github.io/jq/manual/)
- [Bash Documentation](https://www.gnu.org/software/bash/manual/)
- [Chafa Documentation](https://hpjansson.org/chafa/)
- [Figlet Documentation](http://www.figlet.org/)
## Author
- WeWeBunnyX ([@WeWeBunnyX](https://reddit.com/u/WeWeBunnyX))
## Support
If you found this project helpful, please give it a ⭐️!