Description
linenoise is a small, self-contained C library that gives command-line programs line editing and history, as an alternative to GNU readline and libedit. It is minimal and needs no configuration, and it is released under the BSD license. The README names Redis, MongoDB and Android among the projects that use it. Features include single and multi-line editing with the usual key bindings, command history, completion, and hints shown to the right of the prompt as you type. A multiplexing mode can hide and restore the prompt around asynchronous output, bracketed paste folds large pastes on screen, and UTF-8 works, including emoji. The library is about 1,600 lines of code and uses only a subset of VT100 escapes, which the README says is ANSI.SYS compatible. It is meant for small utilities that want line editing without linking a large library.…
Highlights
- Single and multi-line editing with the usual key bindings
- Command history and completion
- Hints shown as you type
- Bracketed paste and UTF-8 with emoji
- About 1,600 lines of BSD-licensed C
Ratings & Reviews
No ratings yet
Be the first to rate Linenoise.
People also visit
Linenoise FAQ
What is linenoise?
A small C library that adds line editing and history to command-line programs, as an alternative to readline and libedit.
Which license does it use?
The BSD license, according to the README.
Why use it instead of readline?
The README says readline is about 30,000 lines and libedit about 20,000, while linenoise is about 1,600 lines. Readline is also GPL licensed.
Which terminals does it work with?
It uses only a subset of VT100 escapes, which the README describes as ANSI.SYS compatible.
Who uses it?
The README names Redis, MongoDB and Android, among other projects.
What are the best Linenoise alternatives?
Popular alternatives to Linenoise include Mle, Ledit and Micro. See all Linenoise alternatives



