# Template file for 'ov'
pkgname=ov
version=0.54.0
revision=1
build_style=go
build_helper=qemu
go_import_path=github.com/noborus/ov
go_ldflags="-X main.Version=${version} -X 'main.Revision=Void Linux'"
make_check_args="-skip TestCommand_Exec|TestExecCommand" # requires /dev/ptmx
short_desc="Feature-rich terminal-based text viewer"
maintainer="Bnyro <bnyro@tutanota.com>"
license="MIT"
homepage="https://noborus.github.io/ov/"
changelog="https://github.com/noborus/ov/releases"
distfiles="https://github.com/noborus/ov/archive/refs/tags/v${version}.tar.gz"
checksum=78248f48adb5deb6ca2e560b57583f0ae66ac5e71704b7dc0b35d2378e0df5ac

post_install() {
	local ov="${DESTDIR}/usr/bin/ov"
	for shell in bash fish zsh; do
		vtargetrun ${ov} --completion ${shell} > ov.${shell}
		vcompletion ov.${shell} ${shell}
	done
	vlicense LICENSE
	vsconf ov.yaml config.yaml
	vsconf ov-less.yaml config-less.yaml
}
