What is ble.sh?
ble.sh, the Bash Line Editor, is a command line editor written in pure Bash that replaces GNU Readline in interactive Bash sessions. You keep Bash, your ~/.bashrc, your aliases and your scripts, and gain what usually means switching shells: syntax highlighting as you type, fish-like auto-suggestions from history, a full vim mode alongside emacs bindings, completion with menus and descriptions, abbreviations, and integration with bash-completion and fzf. It is written by Koichi Murase and released under the BSD-3-Clause licence. There is no binary to run: the package installs the script to /usr/share/blesh/ble.sh, and two lines in your ~/.bashrc turn it on.
apt upgrade.
⚡ Key Features of ble.sh
🎨 Syntax Highlighting
Commands, keywords, strings, variables, redirections and file names are colored as you type, and an unknown command or a syntax error shows up before you press Enter.
💡 Auto-Suggestions
Fish-style suggestions from history and completion appear in gray after the cursor. Accept the whole suggestion with the right arrow or C-f, or one word at a time with M-f.
⌨️ Vim and Emacs Modes
Emacs bindings by default, and a full vi/vim mode with set -o vi: normal, insert and visual modes, text objects, registers and an optional vim-airline-style status line.
📋 Menu Completion
Tab opens a menu of candidates you move through with the arrow keys, with descriptions where available and ambiguous (fuzzy) matching.
✂️ Abbreviations
ble-sabbrev defines abbreviations that expand as you type, like fish abbreviations or zsh global aliases, so L becomes | less.
🐚 Pure Bash, No Binary
Nothing to compile and nothing architecture-specific: ble.sh is a Bash script that runs wherever Bash 3.0 or newer does, and it stays out of non-interactive shells and scripts.
apt upgrade keeps you on the latest version.
📦 Installation from deb.griffo.io
Step 1: Add Repository
sudo install -d -m 0755 /etc/apt/keyrings
curl -fsSL https://deb.griffo.io/EA0F721D231FDD3A0A17B9AC7808B4DD62C41256.asc | sudo gpg --dearmor --yes -o /etc/apt/keyrings/deb.griffo.io.gpg
echo "deb [signed-by=/etc/apt/keyrings/deb.griffo.io.gpg] https://deb.griffo.io/apt $(lsb_release -sc 2>/dev/null) main" | sudo tee /etc/apt/sources.list.d/deb.griffo.io.list > /dev/null
sudo apt updateinstall -d -m 0755 /etc/apt/keyrings
curl -fsSL https://deb.griffo.io/EA0F721D231FDD3A0A17B9AC7808B4DD62C41256.asc | gpg --dearmor --yes -o /etc/apt/keyrings/deb.griffo.io.gpg
echo "deb [signed-by=/etc/apt/keyrings/deb.griffo.io.gpg] https://deb.griffo.io/apt $(lsb_release -sc 2>/dev/null) main" | tee /etc/apt/sources.list.d/deb.griffo.io.list > /dev/null
apt update🆓 There is an always-free mirror. deb-free.griffo.io serves packages free forever, no account, no subscription, at most 2 months behind upstream, security fixes immediately. It currently carries cliamp, Ghostty, lazydocker, Oh My Posh, Uncloud and Zed; ble.sh is not one of them, so the repository above is the only way to get it today, ask and it can be enrolled.
Step 2: Install ble.sh
# Install latest ble.sh
sudo apt install ble.sh
# Optional: vim-airline themes for the vi-mode status line
sudo apt install ble.sh-airline-themes# Install latest ble.sh
apt install ble.sh
# Optional: vim-airline themes for the vi-mode status line
apt install ble.sh-airline-themesStep 3: Enable ble.sh in your ~/.bashrc
# ble.sh has no command to run: Bash loads it from ~/.bashrc.
# Put this line near the TOP of ~/.bashrc:
[[ $- == *i* ]] && source /usr/share/blesh/ble.sh --noattach
# ...the rest of your ~/.bashrc stays as it is...
# And this line at the very END of ~/.bashrc:
[[ ${BLE_VERSION-} ]] && ble-attach
# Open a new terminal, then:
# Verify installation
echo $BLE_VERSION🎯 Basic Usage Examples
Everyday use:
# Check that ble.sh is active in this shell
echo $BLE_VERSION
# Reload ble.sh after changing its settings
ble-reload
# Updates come through apt; ble-update points you there
sudo apt update && sudo apt upgrade# Check that ble.sh is active in this shell
echo $BLE_VERSION
# Reload ble.sh after changing its settings
ble-reload
# Updates come through apt; ble-update points you there
apt update && apt upgradeSettings in ~/.blerc:
# ble.sh reads its settings from ~/.blerc (or ~/.config/blesh/init.sh)
# Vim key bindings instead of emacs
set -o vi
# Wait 300 ms before showing an auto-suggestion
bleopt complete_auto_delay=300
# Turn auto-suggestions off entirely
bleopt complete_auto_complete=
# Change the color of the suggested text
ble-face auto_complete='fg=242'Abbreviations, key bindings and integrations:
# Expand "L" into "| less" as you type
ble-sabbrev L='| less'
# Make Ctrl+C discard the current line
ble-bind -f 'C-c' discard-line
# fzf completion and key bindings, adapted to ble.sh
ble-import -d integration/fzf-completion
ble-import -d integration/fzf-key-bindings
# vim-airline-style status line (needs ble.sh-airline-themes)
ble-import vim-airline
bleopt vim_airline_theme=dark🔧 Tool Integrations
ble.sh sits underneath your existing Bash setup instead of replacing it:
- bash-completion: completions from the
bash-completionpackage are picked up automatically and shown in the menu - fzf:
ble-importloads versions of fzf's completion and key bindings adapted to ble.sh - Atuin: Atuin's Bash integration supports ble.sh, which gives it reliable preexec hooks for recording history
- Starship / Oh My Posh: the prompts they generate keep working unchanged
- Config file:
~/.blercholds yourbleopt,ble-faceandble-bindsettings, separate from~/.bashrc
🚀 Why Choose deb.griffo.io?
- Official Ubuntu: available in universe from 25.10 on, as a snapshot frozen for the life of each release; 22.04 and 24.04 do not have it
- git clone + make: current, but built and installed by hand into
~/.local, and kept up to date withble-updateyourself - deb.griffo.io: latest version with automatic updates
- ✅ Fresh Snapshots: upstream's nightly snapshots, with fixes for new Bash versions and terminals
- ✅ No Manual Setup: no git clone, no
make, no copy of ble.sh in your home directory to keep updated - ✅ Automatic Updates: packages updated within hours of upstream releases
- ✅ Complete Package: the full ble.sh tree in
/usr/share/blesh, its documentation and the optionalble.sh-airline-themespackage - ✅ Every Architecture: shipped as
Architecture: all, so amd64, arm64, armhf, riscv64 and the rest install the same package - ✅ Multi-Distribution: works on Ubuntu 22.04, 24.04, 25.10 and 26.04
- ✅ Easy Maintenance: standard apt commands for updates
📦 Package Build Repository
The Ubuntu packages are automatically built and maintained in this GitHub repository:
- 🖍️ ble.sh-debian - Latest release builds
🔗 Related Packages
Also available from deb.griffo.io:
- fzf - Fuzzy finder that ble.sh integrates with
- Atuin - Shell history in a database, with ble.sh support
- Starship - Cross-shell prompt that works under ble.sh
- zoxide - Smarter cd that learns your directories
~/.bashrc than rewrite it for another shell.
💝 Support This Project
If this repository saves you time and effort, please consider supporting it!