Skip to main content

Search and run shell history with a Textual TUI

Project description

CmdFinder

CmdFinder is a terminal-based user interface (TUI) that lets you fuzzy-search, browse, and execute commands from your shell history. It’s built with Textual and RapidFuzz.

CmdFinder TUI demo

CmdFinder search view


Features

  • 🔍 Fuzzy Search: Quickly find commands even if you don’t remember the exact syntax.
  • 🐚 Shell Support: Reads history from:
    • Zsh: ~/.zsh_history
    • Bash: ~/.bash_history
  • Instant Execution: Select a command and run it immediately in your shell.
  • 🧭 Vim-like Navigation: Navigate with j / k.
  • 🕒 Timestamps: Toggle timestamps on/off.
  • 🎨 Modern TUI: Built using Textual.

Requirements

  • Python 3.10+
  • Bash/Zsh or compatible shell
  • Read access to history files

Installation

pip install cmdfinder

Run:

cmdfinder

or

cf

If the command is not found, add ~/.local/bin to PATH:

echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc

Or for zsh:

echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc

Install from Source

git clone https://github.com/pranav5127/CmdFinder.git
cd cmdfinder

(Optional) create a virtual environment:

python -m venv .venv
source .venv/bin/activate

Install in editable mode:

pip install -e .

Run:

cmdfinder

Usage

To start the TUI:

cmdfinder

Key Bindings

Key Action
j Move down
k Move up
/ Move cursor
Ctrl+s Focus search
l / Ctrl+l Focus list
t Toggle timestamps
Enter Run selected command
q Quit

Run locally:

cmdfinder

or

python -m cmdfinder.app

License

CmdFinder is released under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cmdfinder-1.1.0.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cmdfinder-1.1.0-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file cmdfinder-1.1.0.tar.gz.

File metadata

  • Download URL: cmdfinder-1.1.0.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for cmdfinder-1.1.0.tar.gz
Algorithm Hash digest
SHA256 db122f6de72de7cdb3581e412f008a15ae277f64c373ac4f07c8801e5187af9a
MD5 c48fed45e75098401d43b16a46ac9ab0
BLAKE2b-256 9673dc7ed7a8677f481da00be1b0818525de91142d615dd25a3b6c25a8bbfd8d

See more details on using hashes here.

File details

Details for the file cmdfinder-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: cmdfinder-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for cmdfinder-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 82bdc3284e760a79cd025aee01c44b3a50422fd5d63f40cc4c6480fc53c606bd
MD5 4ea4a3e720b3015ec43751924f186e4e
BLAKE2b-256 9394531173a904bab876787d9e6dbb4413681b45d92019c70712a5464c81e9d3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page