summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-misc/nnn')
-rw-r--r--app-misc/nnn/Manifest5
-rw-r--r--app-misc/nnn/files/nnn-4.9_fix_colemak_patch.patch29
-rw-r--r--app-misc/nnn/metadata.xml27
-rw-r--r--app-misc/nnn/nnn-4.0.ebuild48
-rw-r--r--app-misc/nnn/nnn-4.3.ebuild48
-rw-r--r--app-misc/nnn/nnn-4.5.ebuild50
-rw-r--r--app-misc/nnn/nnn-4.8.ebuild98
-rw-r--r--app-misc/nnn/nnn-4.9.ebuild96
8 files changed, 248 insertions, 153 deletions
diff --git a/app-misc/nnn/Manifest b/app-misc/nnn/Manifest
index 179f6af60cb0..8968e6018682 100644
--- a/app-misc/nnn/Manifest
+++ b/app-misc/nnn/Manifest
@@ -1,3 +1,2 @@
-DIST nnn-4.0.tar.gz 214555 BLAKE2B b0490662bad07213ff79b8865b8d9672d1ff98d93e3705e0aa45d103c151274934dc0cff66731f7b157007a81b9dbb5d9f3edb6a17daddcfb265f73b6faa400e SHA512 fde552a31674c9bf50a2e98de4456621bdc97aee36cd5efd7ad0cc33959965d01469fb20b12868ebffd4c8da79990b502e26895cb5b047ac8821e2ca09b0a234
-DIST nnn-4.3.tar.gz 236606 BLAKE2B cec0a73a40fae76e478c3299e2ae8a613c2e1b16e009d4f69cc3c9c9f6ea5df4048fc7f941ae6369293cf56df9b91a496531f4b34bf05f1dbbf8fab9120ffe78 SHA512 588af174d86db14acf5d1e2ac42f88ca5c6f0e105996a58771e7e0f989f224616e7a12d74fecc96540a9782db0cf8857c21bf0f50df4ee3b4b5c641291c64575
-DIST nnn-4.5.tar.gz 242191 BLAKE2B 2a1564520222bc51df64c495ffa7a22fc3200f4572281e4b4e998e999b41c171f4b832502a054741040fa9d87d0da0d0d23949c0d867fc4c2830722045654c3d SHA512 ab64f0e6211b14e90a4632bb0da9a1214635c9a06718c7c434d344d69d1087b4d5d978d44f38c1b03bb555e3055ca5033bcbca40927135757a468e6f1b99046e
+DIST nnn-4.8.tar.gz 253547 BLAKE2B 36e6e1dc39bfbce7fa72fd322339395fa78a410c93043860be845ff3d5be3178fd37966f57da17f115cab8a6973462d44243052a6c736665ef9a180cd9fd6978 SHA512 932e27ec1d7cd3db6ccba33edb3d1ad2620109cde3c4114b734eef3e04d6c6c22ddaa1c4727908dba2a107dd4cfe1f5193aec450f680a390671f48e63d0133bd
+DIST nnn-4.9.tar.gz 255144 BLAKE2B 3ad257f931dee7803c44f9f4db478a8de0c898a2d8e818457aeb00dcc7936a0a1f51ce3c199a1421a014d197c7f9d2f17bccccbc985b93d78e5994b9cc707c94 SHA512 3c16ed1cbc5466b05306e38c6f5d8eb7ade9cf5ad766f9ff3bf7d20d5bfb9bdf1564527e27191e2cd85542c25245f338e1236630de3d1c8e5fbd10d54d628a14
diff --git a/app-misc/nnn/files/nnn-4.9_fix_colemak_patch.patch b/app-misc/nnn/files/nnn-4.9_fix_colemak_patch.patch
new file mode 100644
index 000000000000..b4078c945753
--- /dev/null
+++ b/app-misc/nnn/files/nnn-4.9_fix_colemak_patch.patch
@@ -0,0 +1,29 @@
+diff --git a/patches/colemak/mainline.diff b/patches/colemak/mainline.diff
+index 09cdfe61..387fde0c 100644
+--- a/patches/colemak/mainline.diff
++++ b/patches/colemak/mainline.diff
+@@ -3,10 +3,10 @@
+ #
+ # Author: github.com/jacmoe
+ diff --git a/src/nnn.c b/src/nnn.c
+-index ecedee43..fdf5a80e 100644
++index 21a7370b..2ddb4053 100644
+ --- a/src/nnn.c
+ +++ b/src/nnn.c
+-@@ -5098,32 +5098,32 @@ static void show_help(const char *path)
++@@ -5109,12 +5109,12 @@ static void show_help(const char *path)
+ "2(___n))\n"
+ "0\n"
+ "1NAVIGATION\n"
+@@ -23,8 +23,9 @@ index ecedee43..fdf5a80e 100644
+ + "9G ^N End%20^J Toggle auto-advance on open\n"
+ "8B (,) Book(mark)%11b ^/ Select bookmark\n"
+ "a1-4 Context%11(Sh)Tab Cycle/new context\n"
+- "62Esc ^Q Quit%20q Quit context\n"
+- "b^G QuitCD%18Q Pick/err, quit\n"
++ "62Esc ^Q Quit%19^y Next young\n"
++@@ -5122,20 +5122,20 @@ static void show_help(const char *path)
++ "cq Quit context\n"
+ "0\n"
+ "1FILTER & PROMPT\n"
+ - "c/ Filter%17^N Toggle type-to-nav\n"
diff --git a/app-misc/nnn/metadata.xml b/app-misc/nnn/metadata.xml
index 48d3ded01150..74ffd32d3078 100644
--- a/app-misc/nnn/metadata.xml
+++ b/app-misc/nnn/metadata.xml
@@ -1,8 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
-<maintainer type="person">
- <email>zlogene@gentoo.org</email>
- <name>Mikle Kolyada</name>
-</maintainer>
+ <maintainer type="person" proxied="yes">
+ <email>gentoo-bugs@ares-macrotechnology.com</email>
+ <name>Sebastian Hamann</name>
+ </maintainer>
+ <maintainer type="project" proxied="proxy">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">jarun/nnn</remote-id>
+ </upstream>
+ <use>
+ <flag name="8contexts">Enable 8 contexts (instead of 4)</flag>
+ <flag name="colemak">Key bindings for Colemak keyboard layout</flag>
+ <flag name="colemak-dh">Key bindings for Colemak-DH keyboard layout</flag>
+ <flag name="emoji">Display icons using emoji</flag>
+ <flag name="gitstatus">Add git status column to the detail view</flag>
+ <flag name="icons">Display icons using icons-in-terminal</flag>
+ <flag name="namefirst">Print filenames first in the detail view</flag>
+ <flag name="nerdfonts">Display icons using nerdfonts icons</flag>
+ <flag name="qsort">Use Alexey Tourbin's quick sort implementation</flag>
+ <flag name="restorepreview">Add pipe to close and restore preview-tui for internal undetached edits</flag>
+ </use>
</pkgmetadata>
diff --git a/app-misc/nnn/nnn-4.0.ebuild b/app-misc/nnn/nnn-4.0.ebuild
deleted file mode 100644
index 0bd65a6f5bf1..000000000000
--- a/app-misc/nnn/nnn-4.0.ebuild
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit bash-completion-r1 toolchain-funcs xdg-utils
-
-DESCRIPTION="The missing terminal file browser for X"
-HOMEPAGE="https://github.com/jarun/nnn"
-SRC_URI="https://github.com/jarun/nnn/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD-2"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc64 ~x86"
-
-DEPEND="sys-libs/ncurses:0=
- sys-libs/readline:0="
-RDEPEND="${DEPEND}"
-
-src_prepare() {
- default
- tc-export CC
- sed -i -e '/install: all/install:/' Makefile || die "sed failed"
-}
-
-src_install() {
- emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install
-
- emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install-desktop
-
- newbashcomp misc/auto-completion/bash/nnn-completion.bash nnn
-
- insinto /usr/share/fish/vendor_completions.d
- doins misc/auto-completion/fish/nnn.fish
-
- insinto /usr/share/zsh/site-functions
- doins misc/auto-completion/zsh/_nnn
-
- einstalldocs
-}
-
-pkg_postinst() {
- xdg_desktop_database_update
-}
-
-pkg_postrm() {
- xdg_desktop_database_update
-}
diff --git a/app-misc/nnn/nnn-4.3.ebuild b/app-misc/nnn/nnn-4.3.ebuild
deleted file mode 100644
index 866305d8ebab..000000000000
--- a/app-misc/nnn/nnn-4.3.ebuild
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit bash-completion-r1 toolchain-funcs xdg-utils
-
-DESCRIPTION="The missing terminal file browser for X"
-HOMEPAGE="https://github.com/jarun/nnn"
-SRC_URI="https://github.com/jarun/nnn/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD-2"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc64 ~x86"
-
-DEPEND="sys-libs/ncurses:0=
- sys-libs/readline:0="
-RDEPEND="${DEPEND}"
-
-src_prepare() {
- default
- tc-export CC
- sed -i -e '/install: all/install:/' Makefile || die "sed failed"
-}
-
-src_install() {
- emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install
-
- emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install-desktop
-
- newbashcomp misc/auto-completion/bash/nnn-completion.bash nnn
-
- insinto /usr/share/fish/vendor_completions.d
- doins misc/auto-completion/fish/nnn.fish
-
- insinto /usr/share/zsh/site-functions
- doins misc/auto-completion/zsh/_nnn
-
- einstalldocs
-}
-
-pkg_postinst() {
- xdg_desktop_database_update
-}
-
-pkg_postrm() {
- xdg_desktop_database_update
-}
diff --git a/app-misc/nnn/nnn-4.5.ebuild b/app-misc/nnn/nnn-4.5.ebuild
deleted file mode 100644
index dbb2eb13d5a1..000000000000
--- a/app-misc/nnn/nnn-4.5.ebuild
+++ /dev/null
@@ -1,50 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit bash-completion-r1 flag-o-matic toolchain-funcs xdg-utils
-
-DESCRIPTION="The missing terminal file browser for X"
-HOMEPAGE="https://github.com/jarun/nnn"
-SRC_URI="https://github.com/jarun/nnn/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD-2"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc64 ~x86"
-
-DEPEND="sys-libs/ncurses:=
- sys-libs/readline:=
- elibc_musl? ( sys-libs/fts-standalone )"
-RDEPEND="${DEPEND}"
-
-src_prepare() {
- default
- tc-export CC
- use elibc_musl && append-flags "-lfts"
- sed -i -e '/install: all/install:/' Makefile || die "sed failed"
-}
-
-src_install() {
- emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install
-
- emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install-desktop
-
- newbashcomp misc/auto-completion/bash/nnn-completion.bash nnn
-
- insinto /usr/share/fish/vendor_completions.d
- doins misc/auto-completion/fish/nnn.fish
-
- insinto /usr/share/zsh/site-functions
- doins misc/auto-completion/zsh/_nnn
-
- einstalldocs
-}
-
-pkg_postinst() {
- xdg_desktop_database_update
-}
-
-pkg_postrm() {
- xdg_desktop_database_update
-}
diff --git a/app-misc/nnn/nnn-4.8.ebuild b/app-misc/nnn/nnn-4.8.ebuild
new file mode 100644
index 000000000000..c4e9d82febc1
--- /dev/null
+++ b/app-misc/nnn/nnn-4.8.ebuild
@@ -0,0 +1,98 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit bash-completion-r1 flag-o-matic toolchain-funcs xdg
+
+DESCRIPTION="The missing terminal file browser for X"
+HOMEPAGE="https://github.com/jarun/nnn"
+SRC_URI="https://github.com/jarun/nnn/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="amd64 ~ppc64 ~x86"
+IUSE="8contexts colemak colemak-dh emoji gitstatus icons namefirst nerdfonts pcre qsort +readline restorepreview"
+
+DEPEND="sys-libs/ncurses:=
+ pcre? ( dev-libs/libpcre )
+ readline? ( sys-libs/readline:= )
+ elibc_musl? ( sys-libs/fts-standalone )"
+BDEPEND="virtual/pkgconfig"
+RDEPEND="${DEPEND}"
+REQUIRED_USE="?? ( icons nerdfonts emoji )
+ ?? ( colemak colemak-dh )"
+
+src_prepare() {
+ default
+ tc-export CC
+ use elibc_musl && append-flags "-lfts"
+ # When using nnn's bundled patches, the 'install' target should not depend
+ # on 'all'. See: https://github.com/jarun/nnn/issues/1493
+ sed -i -e 's/install: all/install:/' Makefile || die "sed failed"
+ # The Makefile uses O_COLEMAK-DH to control the Colemak-DH patch, but that
+ # does not work with the array approach to make options below. Hence, we
+ # simply rename it to O_COLEMAK_DH.
+ sed -i -e 's/O_COLEMAK-DH/O_COLEMAK_DH/' Makefile || die "sed failed"
+}
+
+src_compile() {
+ nnn_opts=(
+ O_NORL=$(usex readline 0 1)
+ O_PCRE=$(usex pcre 1 0)
+ O_CTX8=$(usex 8contexts 1 0)
+ O_ICONS=$(usex icons 1 0)
+ O_NERD=$(usex nerdfonts 1 0)
+ O_EMOJI=$(usex emoji 1 0)
+ O_QSORT=$(usex qsort 1 0)
+ # nnn's user-submitted patches
+ O_COLEMAK=$(usex colemak 1 0)
+ O_COLEMAK_DH=$(usex colemak-dh 1 0)
+ O_GITSTATUS=$(usex gitstatus 1 0)
+ O_NAMEFIRST=$(usex namefirst 1 0)
+ O_RESTOREPREVIEW=$(usex restorepreview 1 0)
+ )
+ emake "${nnn_opts[@]}"
+}
+
+src_install() {
+ emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install
+
+ emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install-desktop
+
+ newbashcomp misc/auto-completion/bash/nnn-completion.bash nnn
+
+ insinto /usr/share/fish/vendor_completions.d
+ doins misc/auto-completion/fish/nnn.fish
+
+ insinto /usr/share/zsh/site-functions
+ doins misc/auto-completion/zsh/_nnn
+
+ einstalldocs
+
+ insinto /usr/share/nnn
+ insopts -m0755
+ doins -r plugins
+ fperms 0644 /usr/share/nnn/plugins/README.md
+}
+
+pkg_postinst() {
+ xdg_pkg_postinst
+
+ elog "nnn plugins are installed to /usr/share/nnn/plugins/, but nnn does not"
+ elog "load them fom this directory. You will need to copy/symlink them to"
+ elog "~/.config/nnn/plugins/ if you want to use them."
+ elog "Note that some plugins have runtime dependencies that may need to be installed."
+ elog "Refer to the individual plugin's in-file documentation for more information."
+
+ if use icons; then
+ elog "In order for file icons to work, your terminal needs to use icons-in-terminal."
+ elog "See https://github.com/sebastiencs/icons-in-terminal"
+ elif use nerdfonts; then
+ elog "In order for file icons to work, your terminal needs to use a patched nerdfont."
+ elog "See https://www.nerdfonts.com/"
+ elif use emoji; then
+ elog "In order for file icons to work, your terminal needs to use a font that"
+ elog "includes standard unicode emoji."
+ fi
+}
diff --git a/app-misc/nnn/nnn-4.9.ebuild b/app-misc/nnn/nnn-4.9.ebuild
new file mode 100644
index 000000000000..d1b0981e38a6
--- /dev/null
+++ b/app-misc/nnn/nnn-4.9.ebuild
@@ -0,0 +1,96 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit bash-completion-r1 flag-o-matic toolchain-funcs xdg
+
+DESCRIPTION="The missing terminal file browser for X"
+HOMEPAGE="https://github.com/jarun/nnn"
+SRC_URI="https://github.com/jarun/nnn/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~x86"
+IUSE="8contexts colemak emoji gitstatus icons namefirst nerdfonts pcre qsort +readline restorepreview"
+
+DEPEND="sys-libs/ncurses:=
+ pcre? ( dev-libs/libpcre )
+ readline? ( sys-libs/readline:= )
+ elibc_musl? ( sys-libs/fts-standalone )"
+BDEPEND="virtual/pkgconfig"
+RDEPEND="${DEPEND}"
+REQUIRED_USE="?? ( icons nerdfonts emoji )"
+
+PATCHES=(
+ "${FILESDIR}/nnn-4.9_fix_colemak_patch.patch"
+)
+
+src_prepare() {
+ default
+ tc-export CC
+ use elibc_musl && append-flags "-lfts"
+ # When using nnn's bundled patches, the 'install' target should not depend
+ # on 'all'. See: https://github.com/jarun/nnn/issues/1493
+ sed -i -e 's/install: all/install:/' Makefile || die "sed failed"
+}
+
+src_compile() {
+ nnn_opts=(
+ O_NORL=$(usex readline 0 1)
+ O_PCRE=$(usex pcre 1 0)
+ O_CTX8=$(usex 8contexts 1 0)
+ O_ICONS=$(usex icons 1 0)
+ O_NERD=$(usex nerdfonts 1 0)
+ O_EMOJI=$(usex emoji 1 0)
+ O_QSORT=$(usex qsort 1 0)
+ # nnn's user-submitted patches
+ O_COLEMAK=$(usex colemak 1 0)
+ O_GITSTATUS=$(usex gitstatus 1 0)
+ O_NAMEFIRST=$(usex namefirst 1 0)
+ O_RESTOREPREVIEW=$(usex restorepreview 1 0)
+ )
+ emake "${nnn_opts[@]}"
+}
+
+src_install() {
+ emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install
+
+ emake PREFIX="${EPREFIX}/usr" DESTDIR="${D}" install-desktop
+
+ newbashcomp misc/auto-completion/bash/nnn-completion.bash nnn
+
+ insinto /usr/share/fish/vendor_completions.d
+ doins misc/auto-completion/fish/nnn.fish
+
+ insinto /usr/share/zsh/site-functions
+ doins misc/auto-completion/zsh/_nnn
+
+ einstalldocs
+
+ insinto /usr/share/nnn
+ insopts -m0755
+ doins -r plugins
+ fperms 0644 /usr/share/nnn/plugins/README.md
+}
+
+pkg_postinst() {
+ xdg_pkg_postinst
+
+ elog "nnn plugins are installed to /usr/share/nnn/plugins/, but nnn does not"
+ elog "load them fom this directory. You will need to copy/symlink them to"
+ elog "~/.config/nnn/plugins/ if you want to use them."
+ elog "Note that some plugins have runtime dependencies that may need to be installed."
+ elog "Refer to the individual plugin's in-file documentation for more information."
+
+ if use icons; then
+ elog "In order for file icons to work, your terminal needs to use icons-in-terminal."
+ elog "See https://github.com/sebastiencs/icons-in-terminal"
+ elif use nerdfonts; then
+ elog "In order for file icons to work, your terminal needs to use a patched nerdfont."
+ elog "See https://www.nerdfonts.com/"
+ elif use emoji; then
+ elog "In order for file icons to work, your terminal needs to use a font that"
+ elog "includes standard unicode emoji."
+ fi
+}