aboutsummaryrefslogtreecommitdiff
path: root/hugo/Staplerfile
blob: 54f84ed28aaaba7fb824c868025ceb6e86e82f53 (plain) (blame)
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
name="hugo"
version="0.164.0"
release=1
summary="The world’s fastest framework for building websites."
desc="Hugo is a static site generator written in Go, optimized for speed and designed for flexibility. With its advanced templating system and fast asset pipelines, Hugo renders a complete site in seconds, often less."
homepage="https://gohugo.io/"
maintainer="Alexander NeonXP Kiryukhin <i@neonxp.ru>"
architectures=("amd64")
license="Apache-2.0"
sources=("https://github.com/gohugoio/hugo/archive/refs/tags/v$version.tar.gz?~name=hugo")
checksums=("SKIP")
# disable_network=1

provides=('hugo')
conflicts=('hugo')

build_deps=('go')

build() {
    mv hugo* hugo
    cd hugo
    export GOPATH=$srcdir/go
    export GOCACHE=$srcdir/cache
    CGO_ENABLED=1 go build -tags extended,withdeploy -ldflags="-s -w" -o $srcdir/dist/ .
    rm -rf $srcdir/go
    rm -rf $srcdir/cache
}

package() {
    install-binary $srcdir/dist/hugo
}

files() {
    files-find-binary
}