Skip to content

ratcrate/ratcrate-cli

πŸ¦€ ratcrate-cli: Ratatui Ecosystem Crate Discoverer

CI Release DocumentationLicense: MIT Crates.io Downloads Rust

πŸ› οΈ Overview

ratcrate-cli is a fast, terminal-native command-line tool built in Rust for discovering, searching, and getting information about crates within the Ratatui ecosystem. It uses a smart caching strategy to provide near-instant results directly in your terminal. The project follows a standard Rust CLI structure, ensuring clear separation of responsibilities:

ratcrate-cli-demo-small

Tip

For more information, read "The book"

✨ Features

  • Offline First: Caches data locally and only downloads when stale (older than 1 day) or forced.
  • Fuzzy Search: Filter crates by name or description using a command-line query.
  • Interactive Mode: Seamless integration with fzf for interactive selection and viewing of crate details.
  • Statistical Breakdown: Quick summary of total, core, and community packages (-t).
  • Flexible Output: Supports both a clean, colored list view and an optional structured table view (--table).

πŸš€ Installation

Prerequisites

  1. Rust Toolchain: You need the latest stable Rust version installed via rustup.
  2. fzf (Optional): Required for the interactive mode (-f).

Install from Crates.io

Once the package is published, you can install it globally:

$> cargo install ratcrate-cli

Using Homebrew

$> brew install rvbug/tap/ratcrate-cli

Homebrew cn be installed via /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Build from Source

Clone the repository and build the project using Cargo:

$> git clone [https://github.com/ratcrate/ratcrate-cli.git](https://github.com/ratcrate/ratcrate-cli.git)
$> cd ratcrate-cli
$> cargo install --path 

Ρ« Usage

Run ratcrate-cli --help for a full list of options.

Option Description
-h, --help Display help information.
-q, --query <QUERY> Search term to filter packages
-c, --cache-info Show cache info
-l, --limit <LIMIT> Limit number of results to show [default: 10]
-r, --refresh Force re-download of remote JSON to cache
-f, --fzf Enable interactive mode with fzf.
-t, --total Display total number of crates.
-V, --version Display the version number.
-h, --help Display help information.
--table Table view (requires compiling with --features table)

Total View

$ ratcrate-cli -t

────────────────────────────────────────────────────────
βœ“ Loaded from cache
Total Crates Overview
────────────────────────────────────────────────────────
Total Crates: 1686
  Core Libraries: 2
  Community Packages: 1684
────────────────────────────────────────────────────────
Data generated at: 2025-12-04T06:10:38.648089+00:00

Table View

$> cargo run --features=table -- --table

ratcrate (discover ratatui crates)
────────────────────────────────────────────────────────
βœ“ Loaded from cache
+-----------------+---------+---------------------------------------------------------------+-----------+-----------------------------------------------------+
| name            | version | description                                                   | downloads | repo                                                |
+-----------------+---------+---------------------------------------------------------------+-----------+-----------------------------------------------------+
| ratatui-macros  | v0.6.0  | Macros for Ratatui                                            | 252104    | https://github.com/ratatui/ratatui                  |
+-----------------+---------+---------------------------------------------------------------+-----------+-----------------------------------------------------+
| ratatui-widgets | v0.2.2  | A collection of Ratatui widgets for building terminal user i… | 123671    | https://github.com/ratatui/ratatui                  |
+-----------------+---------+---------------------------------------------------------------+-----------+-----------------------------------------------------+
| CLI-Rhythm      | v1.0.1  | A simple and functional CLI music player.                     | 5092      | https://github.com/Arklingh/CLI-Rhythm              |
+-----------------+---------+---------------------------------------------------------------+-----------+-----------------------------------------------------+

Query

$> cargo run -- -q parser

ratcrate (discover ratatui crates)
────────────────────────────────────────────────────────
βœ“ Loaded from cache
Results: 8 / 8
Query: parser
────────────────────────────────────────────────────────────
 1. codex_usage v0.1.1
  Codex and Claude Code telemetry/usage parser, aggregate JSONL events
  into CodeAnalysis results
  Downloads: 262   Repo: https://github.com/Mai0313/codex_usage
────────────────────────────────────────────────────────────
 2. keybinds v0.2.0
  Platform&Framework-agnostic key binding (keyboard shortcut) dispatcher,
  parser, and generator written in Safe Rust.
  Downloads: 9140   Repo: https://github.com/rhysd/keybinds-rs

Roadmap

  • "Try" mode
  • Debian Support

🀝 Contributing

Contributions are welcome! If you have suggestions or find a bug, please open an issue or submit a pull request.

πŸ“ License

This project is licensed under the MIT License. See the LICENSE file for details.



Support

If you find my projects helpful or want to support my research and open-source work:

Ko-fi

About

Discover, Search Rust Crates using Ratatui.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages