https://github.com/apoorvalal/richcli
python CLI for interacting with unix tools built for people who haven't committed manpages to memory
https://github.com/apoorvalal/richcli
cli ffmpeg pdftk python unix
Last synced: 4 months ago
JSON representation
python CLI for interacting with unix tools built for people who haven't committed manpages to memory
- Host: GitHub
- URL: https://github.com/apoorvalal/richcli
- Owner: apoorvalal
- Created: 2025-03-09T19:28:30.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-01-13T05:02:52.000Z (5 months ago)
- Last Synced: 2026-01-13T08:33:08.671Z (5 months ago)
- Topics: cli, ffmpeg, pdftk, python, unix
- Language: Python
- Homepage:
- Size: 27.3 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# `richcli`: user-friendly terminal interfaces
User-friendly Terminal User Interfaces (TUI) for intimidating unix tools, built with the [rich](https://rich.readthedocs.io/en/stable/introduction.html) python library for modern terminal interfaces. The flagship “magnet” mode parses a CLI’s `-h/--help` output and walks new users through building a safe, explicit command line. Prebuilt FFmpeg and pdftk flows remain available for the most common media and PDF operations.
## Features
### Magnet: interactive builder for any CLI
- Parse a command’s help text and list detected options and arguments
- Add flags, positional arguments, and values with prompts that explain requirements
- Pipe help text in (`mytool --help | richcli magnet mytool`) when the tool needs special flags to show usage
- Save or run the assembled command after preview
Example of building up a pandoc command to convert a markdown file to html:
[](https://asciinema.org/a/YLkkZAKHf3fMEVKoZD2mTYgRW)
### Media conversion/slicing: FFmpeg presets
- Convert between media formats
- Resize videos
- Trim media files
- Adjust audio settings
Example of slicing an mp3 with timestamps:
[](https://asciinema.org/a/9RO8sgs6USJcdUtfAXNp0icZe)
### PDF tools: pdftk and ghostscript operations
- Extract pages
- Merge PDFs
- Compress PDFs
- Rotate pages
- Add page numbers
- Split PDFs
Example of slicing a pdf (potentially to upload into a RAG / LLM's context):
[](https://asciinema.org/a/ORABjxo0qCnuAKX6IUYvaUO6r)
## Installation
### From Source
```bash
git clone https://github.com/apoorvalal/richcli.git
cd richcli
pip install -e .
```
### Dependencies
- Python 3.7+
- Rich library (installed automatically by pip)
- External tools:
- PDF Tools requires:
- pdftk
- ghostscript
- FFmpeg UI requires:
- ffmpeg
## Usage
### Launch specific tools directly:
```bash
richcli magnet # Generic builder for any CLI (magnet mode)
richcli # Shortcut: jump straight into magnet for that command
richcli ffmpeg # FFmpeg UI presets
richcli pdf # PDF Tools presets
```
### Launch the main UI:
```bash
richcli
```
The main menu defaults to magnet mode so first-time CLI users can start with the guided builder, with FFmpeg and pdftk available as ready-made presets.
### Navigation
At any prompt you can type `b` to go back to the previous menu or `q`/`quit` to exit the current tool without relying on Ctrl+C/Ctrl+D.