blob: adde3506bd6a44b0982cc88297f9d958b921dc40 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
# Contributor: Thomas Boerger <thomas@webhippie.de>
# Maintainer: Thomas Boerger <thomas@webhippie.de>
pkgname=hugo
pkgver=0.69.2
pkgrel=1
pkgdesc="A Fast and Flexible Static Site Generator built with love in GoLang"
url="https://gohugo.io/"
arch="all !x86 !s390x !mips !mips64" # tests fail on x86, s390x and mips
license="Apache-2.0"
makedepends="go"
subpackages="$pkgname-doc $pkgname-bash-completion:bashcomp:noarch"
source="
$pkgname-$pkgver.tar.gz::https://github.com/gohugoio/hugo/archive/v$pkgver.tar.gz
0001-Remove-git-tests.patch
0002-skip-tests-that-need-nodejs.patch
"
build() {
go build -v -o bin/$pkgname --tags extended
./bin/hugo gen man
./bin/hugo gen autocomplete --completionfile="$builddir"/hugo.bash
}
check() {
# image_test.so:548 fails
case "$CARCH" in
aarch64|ppc64le) return 0 ;;
esac
go test ./...
}
package() {
install -Dm755 "$builddir"/bin/$pkgname "$pkgdir"/usr/bin/$pkgname
install -Dm644 "$builddir"/man/*.1 -t "$pkgdir"/usr/share/man/man1
}
bashcomp() {
depends=""
pkgdesc="Bash completions for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
install -Dm644 "$builddir"/hugo.bash \
"$subpkgdir"/usr/share/bash-completion/completions/hugo
}
sha512sums="3433bf4c5f0ee3e11ab1305ce76bac6f4982df12fe0d5e778c47d9ff0d98bc01efcac7a430d897e8fa7fd990604371c58f9b6e56cf105bf78232d04c7371737d hugo-0.69.2.tar.gz
54dc7012d67b7970bceb9d4423d9c5971fd9875b5e566f1ab8ae07a11fdb009c379b55ebbbb3a0f74d530de9075ed1794acc42274ef6460381db98116acfe0a7 0001-Remove-git-tests.patch
c1cb94376363dd6898bb842c2c26dc5b35dc2a862d4e3dcbf18214c59bc36d93330ff0686bd4cf27a58456a2afa32886c85d63a0c445ede910bc794fb77ba79a 0002-skip-tests-that-need-nodejs.patch"
|