Skip to content

Commit fa441ba

Browse files
rlwrap: add package
rlwrap is a 'readline wrapper', a small utility that uses the GNU Readline library to allow the editing of keyboard input for any command. The input history is preserved even across different invocations, history search and completion are supported Co-authored-by: George Sapkin <[email protected]> Signed-off-by: Jeronimo Pellegrini <[email protected]>
1 parent 7917119 commit fa441ba

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

utils/rlwrap/Makefile

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# SPDX-License-Identifier: GPL-2.0-only
2+
3+
include $(TOPDIR)/rules.mk
4+
5+
PKG_NAME:=rlwrap
6+
PKG_VERSION:=0.48
7+
PKG_RELEASE:=1
8+
9+
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
10+
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
11+
PKG_SOURCE_URL:=https://github.com/hanslub42/rlwrap/releases/download/v$(PKG_VERSION)/
12+
PKG_HASH:=cdf69074a216a8284574dddd145dd046c904ad5330a616e0eed53c9043f2ecbc
13+
14+
PKG_MAINTAINER:=Jeronimo Pellegrini <[email protected]>
15+
PKG_LICENSE:=GPL-2.0-only
16+
PKG_LICENSE_FILES:=COPYING
17+
18+
include $(INCLUDE_DIR)/package.mk
19+
20+
define Package/rlwrap
21+
TITLE:=rlwrap
22+
SECTION:=utils
23+
CATEGORY:=Utilities
24+
URL:=https://github.com/hanslub42/rlwrap
25+
DEPENDS:= +libreadline +libncursesw
26+
endef
27+
28+
define Package/rlwrap/description
29+
rlwrap is a 'readline wrapper', a small utility that uses the GNU Readline library
30+
to allow the editing of keyboard input for any command.
31+
The input history is preserved even across different invocations, history search
32+
and completion are supported
33+
endef
34+
35+
CONFIGURE_ARGS += --without-libptytty
36+
37+
define Package/rlwrap/install
38+
$(INSTALL_DIR) $(1)/usr/bin
39+
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/rlwrap $(1)/usr/bin
40+
endef
41+
42+
$(eval $(call BuildPackage,rlwrap))

utils/rlwrap/test.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/sh
2+
3+
rlwrap -v 2>&1 | grep "$2"
4+

0 commit comments

Comments
 (0)