summaryrefslogtreecommitdiff
path: root/misc/qman
diff options
context:
space:
mode:
Diffstat (limited to 'misc/qman')
-rw-r--r--misc/qman/Makefile61
-rw-r--r--misc/qman/distinfo3
-rw-r--r--misc/qman/files/patch-config_qman.conf12
-rw-r--r--misc/qman/pkg-descr10
-rw-r--r--misc/qman/pkg-plist8
5 files changed, 94 insertions, 0 deletions
diff --git a/misc/qman/Makefile b/misc/qman/Makefile
new file mode 100644
index 000000000000..350c241b60ee
--- /dev/null
+++ b/misc/qman/Makefile
@@ -0,0 +1,61 @@
+PORTNAME= qman
+PORTVERSION= 1.4.2.20250630
+CATEGORIES= misc
+
+MAINTAINER= tagattie@FreeBSD.org
+COMMENT= More modern man page viewer for our terminals
+WWW= https://github.com/plp13/qman
+
+LICENSE= BSD2CLAUSE
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+BUILD_DEPENDS= cog:devel/py-cogapp
+
+USES= groff:run meson pkgconfig
+
+USE_GITHUB= yes
+GH_ACCOUNT= plp13
+GH_TAGNAME= 16b4e808ab619d7bfb7d94017ca9505b69a387fb
+
+MESON_ARGS= -Dconfigdir=${PREFIX}/etc/xdg/${PORTNAME} \
+ -Ddocs=disabled \
+ -Dtests=disabled
+
+OPTIONS_DEFINE= BZIP2 DOCS GZIP LZMA MANPAGES
+OPTIONS_DEFAULT=BZIP2 GZIP LZMA MANPAGES
+OPTIONS_SUB= yes
+
+BZIP2_DESC= Support bzip2-compressed manual pages
+GZIP_DESC= Support gzip-compressed manual pages
+LZMA_DESC= Support xz-compressed manual pages
+
+BZIP2_MESON_ENABLED= bzip2
+GZIP_MESON_ENABLED= gzip
+LZMA_MESON_ENABLED= lzma
+MANPAGES_MESON_ENABLED= man-pages
+
+PORTDOCS= BUILDING.md CONTRIBUTING.md DEBUGGING.md OS_SPECIFIC.md \
+ README.md TESTING.md TROUBLESHOOTING.md
+
+.include <bsd.port.options.mk>
+
+# FreeBSD 13 is missing /usr/libdata/pkgconfig/ncursesw.pc
+.if ${OPSYS} == FreeBSD && ${OSREL:R} == 13
+USES+= ncurses:port
+.else
+USES+= ncurses
+.endif
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|' \
+ ${WRKSRC}/config/qman.conf
+ @${REINPLACE_CMD} -e 's|/etc|${PREFIX}&|' \
+ ${WRKSRC}/src/config.c.cog ${WRKSRC}/src/config.h.cog
+
+post-install-DOCS-on:
+ @${MKDIR} ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_MAN} ${WRKSRC}/README.md ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_MAN} ${PORTDOCS:S|README.md||:S|^|${WRKSRC}/doc/|} ${STAGEDIR}${DOCSDIR}
+
+
+.include <bsd.port.mk>
diff --git a/misc/qman/distinfo b/misc/qman/distinfo
new file mode 100644
index 000000000000..a727c006d449
--- /dev/null
+++ b/misc/qman/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1752607509
+SHA256 (plp13-qman-1.4.2.20250630-16b4e808ab619d7bfb7d94017ca9505b69a387fb_GH0.tar.gz) = 8b950c83bae0bd0fa5bd67d549b9044f152aae5925a1cf804cc56228272cabaa
+SIZE (plp13-qman-1.4.2.20250630-16b4e808ab619d7bfb7d94017ca9505b69a387fb_GH0.tar.gz) = 952625
diff --git a/misc/qman/files/patch-config_qman.conf b/misc/qman/files/patch-config_qman.conf
new file mode 100644
index 000000000000..f5bc89c71f78
--- /dev/null
+++ b/misc/qman/files/patch-config_qman.conf
@@ -0,0 +1,12 @@
+--- config/qman.conf.orig 2025-07-15 19:28:48 UTC
++++ config/qman.conf
+@@ -21,6 +21,9 @@ enable= true
+ ; flicker after opening an email link
+ ; reset_after_email= false
+
++system_type= freebsd
++groff_path= %%LOCALBASE%%/bin/groff
++
+ [layout]
+
+ ; Change this to suit your terminal window size
diff --git a/misc/qman/pkg-descr b/misc/qman/pkg-descr
new file mode 100644
index 000000000000..09396e416fd4
--- /dev/null
+++ b/misc/qman/pkg-descr
@@ -0,0 +1,10 @@
+Unix manual pages are lovely. They are concise, well-written,
+complete, and downright useful. However, the standard way of accessing
+them from the command-line hasn't changed since the early days.
+
+Qman aims to change that. It's a modern, full-featured manual page
+viewer featuring hyperlinks, web browser like navigation, a table of
+contents for each page, incremental search, on-line help, and more. It
+also strives to be fast and tiny, so that it can be used
+everywhere. For this reason, it's been written in plain C and has only
+minimal dependencies.
diff --git a/misc/qman/pkg-plist b/misc/qman/pkg-plist
new file mode 100644
index 000000000000..0472e626d2bc
--- /dev/null
+++ b/misc/qman/pkg-plist
@@ -0,0 +1,8 @@
+bin/qman
+etc/xdg/qman/qman.conf
+etc/xdg/qman/themes/adwaita-light.conf
+etc/xdg/qman/themes/adwaita.conf
+etc/xdg/qman/themes/catppuccin_latte.conf
+etc/xdg/qman/themes/modernity-light.conf
+etc/xdg/qman/themes/modernity.conf
+%%MANPAGES%%share/man/man1/qman.1.gz