navi — Interactive Cheatsheet Tool for the Command Line
navi turns cheatsheets into executable commands. Browse a fuzzy-finder list of snippets (git, docker, kubectl, ffmpeg), fill in parameters with interactive prompts, and run — no more copy-pasting from Stack Overflow.
What it is
navi is a Rust-based command-line tool that turns plain-text cheatsheets into an interactive, executable interface. You search for a command by description (e.g., 'rebase last N commits'), navi shows matching snippets with parameter placeholders, you fill them in, and the command runs.
It is built for developers and sysadmins who work across multiple CLI tools -- git, docker, kubectl, ffmpeg, aws -- and cannot keep every flag combination in memory. Community-maintained cheatsheet repositories cover hundreds of tools out of the box.
How it saves time or tokens
Instead of opening a browser, searching Stack Overflow, copying a command, and adapting it to your situation, navi keeps the entire lookup-to-execution cycle inside the terminal. A single keystroke (Ctrl+G when configured as a shell widget) opens fuzzy search over all your cheatsheets.
For AI agent workflows, navi cheatsheets serve as structured command references that agents can parse. The .cheat file format is simple enough that an LLM can generate new cheatsheets on demand.
How to use
- Install navi:
# macOS
brew install navi
# Or via Cargo
cargo install navi
- Run
navito open the interactive fuzzy finder. On first launch, it prompts you to install community cheatsheets.
- Add shell integration for instant access:
# Add to ~/.zshrc
eval "$(navi widget zsh)"
# Now Ctrl+G opens navi anywhere
Example
A .cheat file entry looks like this:
% git, rebase
# Interactively rebase the last N commits
git rebase -i HEAD~<n>
$ n: echo '3 5 10' | tr ' ' '\n'
When you search for 'rebase' in navi, this entry appears. You select it, navi prompts for n with suggested values (3, 5, 10), and runs git rebase -i HEAD~5 for you.
# Using navi with a specific cheat repo
navi --path ~/my-cheats
# Preview mode (shows command without running)
navi --print
# Add a community repo
navi repo add denisidoro/cheats
Related on TokRepo
- CLI and Automation Tools -- More terminal productivity tools for developers
- AI Tools for Coding -- AI-powered development tools that pair well with CLI workflows
Common pitfalls
- navi requires fzf or skim for fuzzy search. If neither is installed, it falls back to a basic selector that lacks fuzzy matching.
- Custom
.cheatfiles must follow the exact format:%for tags,#for descriptions,$for variable suggestions. Deviating from this format causes silent parse failures. - Shell widget integration (Ctrl+G) only works after restarting your shell or sourcing your rc file. Forgetting to reload is the most common setup complaint.
Frequently Asked Questions
tldr and cheat.sh are read-only references -- they show you the command but you still copy-paste and edit it. navi is interactive: it prompts for parameters and can execute the command directly. It also supports custom private cheatsheets alongside community ones.
Yes. Create `.cheat` files in `~/.local/share/navi/cheats/` or any directory you point navi to. The format uses `%` for tags, `#` for descriptions, and `$` for parameter suggestions. See the navi GitHub wiki for the full syntax reference.
Yes. navi supports bash, zsh, fish, and elvish. The shell widget command differs per shell: use `navi widget fish` for fish integration. The interactive fuzzy search and command execution work identically across shells.
The `.cheat` file format is plain text with a simple structure, making it easy for LLMs to read, generate, or modify. An AI agent could generate project-specific cheatsheets and add them to a navi directory for the user.
Run `navi repo browse` to see available repositories, or `navi repo add <repo>` to add a specific one. To update existing repos, navigate to the cheatsheet directory and run `git pull` in each cloned repository.
Citations (3)
- navi GitHub Repository— navi is an interactive cheatsheet tool for the command line
- navi README— Supports bash, zsh, fish, and elvish shell integration
- navi Cheat Repositories— Community cheatsheets cover git, docker, kubectl, and hundreds more tools
Related on TokRepo
Discussion
Related Assets
Moodle — Open-Source Learning Management System
The most widely used open-source learning platform, providing course management, assessments, and collaboration tools for educators and organizations worldwide.
Sylius — Headless E-Commerce Framework on Symfony
An open-source headless e-commerce platform built on Symfony and API Platform, designed for developers who need a customizable and API-first commerce solution.
Akaunting — Free Self-Hosted Accounting Software
A free, open-source online accounting application built on Laravel for small businesses and freelancers to manage invoices, expenses, and financial reports.