# Template file for 'zola'
pkgname=zola
version=0.23.3
revision=1
build_style=cargo
build_helper=qemu
hostmakedepends="pkg-config"
makedepends="libzstd-devel oniguruma-devel"
short_desc="Fast opinionated static site generator"
maintainer="classabbyamp <void@placeviolette.net>"
license="EUPL-1.2"
homepage="https://github.com/getzola/zola"
changelog="https://raw.githubusercontent.com/getzola/zola/master/CHANGELOG.md"
distfiles="https://github.com/getzola/zola/archive/refs/tags/v${version}.tar.gz"
checksum=2028bb1608b9625f78634c75b62654583fa3214fadac7e5f448a6b59b68912ec

post_install() {
	for _shell in bash fish zsh; do
		vtargetrun ${DESTDIR}/usr/bin/zola completion ${_shell} > zola.${_shell}
		vcompletion zola.${_shell} ${_shell}
	done

	vlicense LICENSE

	ln -s zola ${DESTDIR}/usr/bin/gutenberg
}

gutenberg_package() {
	depends="zola-${version}_${revision}"
	short_desc="Transition package for Zola"
	pkg_install() {
		vmove usr/bin/gutenberg
	}
}
