From 27c2cc3cc9d2b0e35e93a757c8d91db571df83d5 Mon Sep 17 00:00:00 2001 From: Yuri Victorovich Date: Mon, 6 Nov 2017 18:51:08 +0000 Subject: [PATCH] New port: textproc/fzy: Interactive fuzzy text selector for the terminal Committed with minor changes. PR: 223337 Submitted by: Oleh Hushchenkov Approved by: tcberner (mentor) Differential Revision: https://reviews.freebsd.org/D12971 --- textproc/Makefile | 1 + textproc/fzy/Makefile | 46 ++++++++++++++++++++++++++++++++++++++++++ textproc/fzy/distinfo | 3 +++ textproc/fzy/pkg-descr | 10 +++++++++ 4 files changed, 60 insertions(+) create mode 100644 textproc/fzy/Makefile create mode 100644 textproc/fzy/distinfo create mode 100644 textproc/fzy/pkg-descr diff --git a/textproc/Makefile b/textproc/Makefile index 078fd54f819d..3135d6b5ac23 100644 --- a/textproc/Makefile +++ b/textproc/Makefile @@ -208,6 +208,7 @@ SUBDIR += freexl SUBDIR += fy-aspell SUBDIR += fzf + SUBDIR += fzy SUBDIR += ga-aspell SUBDIR += gastex SUBDIR += gd-aspell diff --git a/textproc/fzy/Makefile b/textproc/fzy/Makefile new file mode 100644 index 000000000000..c4b8d83f1c79 --- /dev/null +++ b/textproc/fzy/Makefile @@ -0,0 +1,46 @@ +# $FreeBSD$ + +PORTNAME= fzy +DISTVERSION= 0.9 +CATEGORIES= textproc + +MAINTAINER= gor@clogic.com.ua +COMMENT= Interactive fuzzy text selector for the terminal + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +USES= gmake +USE_GITHUB= yes +GH_ACCOUNT= jhawthorn + +PLIST_FILES= bin/fzy man/man1/fzy.1.gz + +OPTIONS_DEFINE= TMUX DVTM +OPTIONS_DEFAULT= TMUX +TMUX_DESC= Install fzy-tmux +DVTM_DESC= Install fzy-dvtm + +TMUX_PLIST_FILES= bin/fzy-tmux +DVTM_PLIST_FILES= bin/fzy-dvtm + +post-extract: + ${CP} ${WRKSRC}/src/config.def.h ${WRKSRC}/config.h + +post-patch: + @${REINPLACE_CMD} \ + -e 's, -g,,g' \ + -e 's, -O3,,g' \ + ${WRKSRC}/Makefile + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/fzy ${STAGEDIR}${PREFIX}/bin + ${INSTALL_MAN} ${WRKSRC}/fzy.1 ${STAGEDIR}${MANPREFIX}/man/man1/ + +do-install-TMUX-on: + ${INSTALL_SCRIPT} ${WRKSRC}/contrib/fzy-tmux ${STAGEDIR}${PREFIX}/bin + +do-install-DVTM-on: + ${INSTALL_SCRIPT} ${WRKSRC}/contrib/fzy-dvtm ${STAGEDIR}${PREFIX}/bin + +.include diff --git a/textproc/fzy/distinfo b/textproc/fzy/distinfo new file mode 100644 index 000000000000..da5bcc8d0f71 --- /dev/null +++ b/textproc/fzy/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1509430593 +SHA256 (jhawthorn-fzy-0.9_GH0.tar.gz) = 72182686806ddce7807d85c27efc321a1b01087643ce8006b1225e3617eecff5 +SIZE (jhawthorn-fzy-0.9_GH0.tar.gz) = 42992 diff --git a/textproc/fzy/pkg-descr b/textproc/fzy/pkg-descr new file mode 100644 index 000000000000..09bc7e5bc597 --- /dev/null +++ b/textproc/fzy/pkg-descr @@ -0,0 +1,10 @@ +Fuzzy finder written on C. fzy is faster and shows better results than other +fuzzy finders. Most other fuzzy matchers sort based on the length of a match. +fzy tries to find the result the user intended. It does this by favouring +matches on consecutive letters and starts of words. This allows matching using +acronyms or different parts of the path. fzy is designed to be used both as an +editor plugin and on the command line. Rather than clearing the screen, fzy +displays its interface directly below the current cursor position, scrolling +the screen if necessary. + +WWW: https://github.com/jhawthorn/fzy