All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH nftables 0/3] Add Linenoise support to the CLI.
@ 2019-09-21 12:20 Jeremy Sowden
  2019-09-21 12:20 ` [PATCH nftables 1/3] src, include: add upstream linenoise source Jeremy Sowden
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Jeremy Sowden @ 2019-09-21 12:20 UTC (permalink / raw)
  To: Pablo Neira Ayuso; +Cc: Netfilter Devel, Sebastian Priebe

Sebastian Priebe [0] requested Linenoise support for the CLI as an
alternative to Readline, so I thought I'd have a go at providing it.
Linenoise is a minimal, zero-config, BSD licensed, Readline replacement
used in Redis, MongoDB, and Android [1].

 0 - https://lore.kernel.org/netfilter-devel/4df20614cd10434b9f91080d0862dd0c@de.sii.group/
 1 - https://github.com/antirez/linenoise/

The upstream repo doesn't contain the infrastructure for building or
installing libraries.  I've taken a look at how Redis and MongoDB handle
this, and they both include the upstream sources in their trees (MongoDB
actually uses a C++ fork, Linenoise NG [2]), so I've done the same.

 2 - https://github.com/arangodb/linenoise-ng

By default, the CLI continues to be build using Readline, but passing
`--with-cli=linenoise` instead causes Linenoise to be used instead.

`nft -v` has been extended to display what CLI implementation was built
and whether mini-gmp was used.

Changes since RFC:

 * two tidy-up patches dropped because they have already been applied;
 * source now added to include/ and src/;
 * tests/build/run-tests.sh updated to test `--with-cli=linenoise`;
 * `nft -v` extended.

Jeremy Sowden (3):
  src, include: add upstream linenoise source.
  cli: add linenoise CLI implementation.
  main: add more information to `nft -v`.

 configure.ac             |   14 +-
 include/Makefile.am      |    1 +
 include/cli.h            |    2 +-
 include/linenoise.h      |   73 +++
 src/Makefile.am          |   12 +
 src/cli.c                |   64 +-
 src/linenoise.c          | 1201 ++++++++++++++++++++++++++++++++++++++
 src/main.c               |   28 +-
 tests/build/run-tests.sh |    4 +-
 9 files changed, 1381 insertions(+), 18 deletions(-)
 create mode 100644 include/linenoise.h
 create mode 100644 src/linenoise.c

-- 
2.23.0


^ permalink raw reply	[flat|nested] 13+ messages in thread
* [PATCH nftables 0/3] Add Linenoise support to the CLI.
@ 2019-09-24  7:40 Jeremy Sowden
  2019-09-24  7:40 ` [PATCH nftables 1/3] src, include: add upstream linenoise source Jeremy Sowden
  0 siblings, 1 reply; 13+ messages in thread
From: Jeremy Sowden @ 2019-09-24  7:40 UTC (permalink / raw)
  To: Pablo Neira Ayuso; +Cc: Netfilter Devel, Sebastian Priebe

Sebastian Priebe [0] requested Linenoise support for the CLI as an
alternative to Readline, so I thought I'd have a go at providing it.
Linenoise is a minimal, zero-config, BSD licensed, Readline replacement
used in Redis, MongoDB, and Android [1].

 0 - https://lore.kernel.org/netfilter-devel/4df20614cd10434b9f91080d0862dd0c@de.sii.group/
 1 - https://github.com/antirez/linenoise/

The upstream repo doesn't contain the infrastructure for building or
installing libraries.  I've taken a look at how Redis and MongoDB handle
this, and they both include the upstream sources in their trees (MongoDB
actually uses a C++ fork, Linenoise NG [2]), so I've done the same.

 2 - https://github.com/arangodb/linenoise-ng

By default, the CLI continues to be build using Readline, but passing
`--with-cli=linenoise` instead causes Linenoise to be used instead.

`nft -v` has been extended to display what CLI implementation was built
and whether mini-gmp was used.

Changes since RFC:

 * two tidy-up patches dropped because they have already been applied;
 * source now added to include/ and src/;
 * tests/build/run-tests.sh updated to test `--with-cli=linenoise`;
 * `nft -v` extended.

Jeremy Sowden (3):
  src, include: add upstream linenoise source.
  cli: add linenoise CLI implementation.
  main: add more information to `nft -v`.

 configure.ac             |   14 +-
 include/Makefile.am      |    1 +
 include/cli.h            |    2 +-
 include/linenoise.h      |   73 +++
 src/Makefile.am          |   12 +
 src/cli.c                |   64 +-
 src/linenoise.c          | 1201 ++++++++++++++++++++++++++++++++++++++
 src/main.c               |   28 +-
 tests/build/run-tests.sh |    4 +-
 9 files changed, 1381 insertions(+), 18 deletions(-)
 create mode 100644 include/linenoise.h
 create mode 100644 src/linenoise.c

-- 
2.23.0


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2019-09-24  7:40 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-21 12:20 [PATCH nftables 0/3] Add Linenoise support to the CLI Jeremy Sowden
2019-09-21 12:20 ` [PATCH nftables 1/3] src, include: add upstream linenoise source Jeremy Sowden
2019-09-21 19:19   ` Jan Engelhardt
2019-09-22  7:09     ` Pablo Neira Ayuso
2019-09-22  9:22       ` Jeremy Sowden
2019-09-22 22:28         ` Jeremy Sowden
2019-09-23  8:47       ` Jan Engelhardt
2019-09-23  9:27         ` Pablo Neira Ayuso
2019-09-23 18:15           ` Jeremy Sowden
2019-09-24  6:38             ` AW: " Priebe, Sebastian
2019-09-21 12:20 ` [PATCH nftables 2/3] cli: add linenoise CLI implementation Jeremy Sowden
2019-09-21 12:21 ` [PATCH nftables 3/3] main: add more information to `nft -v` Jeremy Sowden
  -- strict thread matches above, loose matches on Subject: below --
2019-09-24  7:40 [PATCH nftables 0/3] Add Linenoise support to the CLI Jeremy Sowden
2019-09-24  7:40 ` [PATCH nftables 1/3] src, include: add upstream linenoise source Jeremy Sowden

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.