[buildout]
extends =
  ../golang/buildout.cfg

parts =
  slapos-cookbook
  gowork

[hugo-get]
<= go-git-package
go.importpath = github.com/gohugoio/hugo
repository    = https://github.com/gohugoio/hugo.git
revision      = f6821b88abbc1237af0e28cefbc624e6cda3305a

[gowork]
install =
  ${hugo-get:location}:./...
environment =
  CGO_ENABLED = 1
buildflags = --tags extended

[gowork.goinstall]
depends_gitfetch  =
    ${hugo-get:recipe}

command = set -e
  . ${gowork:env.sh}
  cd ${hugo-get:location}
  go build ${gowork:buildflags} -o ${gowork:bin}/hugo

[hugo]
<= gowork.goinstall
