home shape

Linenoise-ng: Command Line Editing Library

For projects that are BSD or Apache 2 licensed, Linenoise (by Salvatore Sanfilippo) is a pretty small, portable GNU readline (GPL) replacement. Based on the work of Salvatore and 10gen Inc. this Linenoise NG implementation adds UTF8 and Windows support, uses a BSD license and can be used in any kind of program.

Features:

  • single-line and multi-line editing mode with the usual key bindings implemented
  • history handling
  • completion
  • BSD license source code
  • Only uses a subset of VT100 escapes (ANSI.SYS compatible)
  • UTF8 aware
  • support for Linux, MacOS and Windows

Linenoise NG deviates from Salvatore’s original goal to have a minimal readline replacement for the sake of supporting UTF8 and Windows. It deviates from 10gen Inc.’s goal to create a C++ interface to linenoise. This library uses C++ internally, but to the user it provides a pure C interface that is compatible with the original linenoise API.

Contributions welcome! See the repository on Github for details.

Ingo

Ingo Friepoertner

Ingo is dealing with all the good ideas from the ArangoDB community, customers and industry experts to improve the value provided by the company’s native multi-model approach. In former positions he worked as a product owner and tech consultant, building custom software solutions for large companies in various industries. Ingo holds a diploma in business informatics from FHDW University of Applied Sciences.

Leave a Comment





Get the latest tutorials, blog posts and news: