$ show akinomyoga/ble.sh
ble.sh is a pure Bash line editor that replaces GNU Readline for interactive shell sessions. It provides syntax highlighting, advanced tab completion, Vi/Emacs keybindings, a status line, and a full hook/configuration framework. The codebase is modular with namespaced functions (ble/), lazy loading via ble-import, and extensive caching for performance. It integrates deeply with Bash internals and includes workarounds for bugs across Bash versions 3.0 through 5.3. While the core is highly polished and well-architected, some areas show accumulated complexity from version-specific hacks and large generated Unicode data files. The repository is actively maintained with frequent commits, responsive issue triage, and a large community.
The LLM identified 2 files worth highlighting for reuse:
Implements a modular background process management utility with deferred start, timeouts, restart, and lifecycle hooks via FIFO pipes. The component is self-contained and can be extracted for any shell script needing to manage long-running background processes with controlled lifecycles.
Provides blehook, a centralized hook system with sandboxed invocation, wildcard matching, and array-based storage. The pattern is cleanly abstracted and reusable for any event-driven shell application, supporting custom signals and integration with readline.