Commit 3e949836 authored by Kirill Smelkov's avatar Kirill Smelkov

golang: Make gowork.install optional

Some software releases - e.g. wendelin.core - only use ${go:exe} and
does not put anything into ${gowork:install}.
parent 149252e0
...@@ -103,7 +103,7 @@ environment-extra = ...@@ -103,7 +103,7 @@ environment-extra =
# buildflags = -race # buildflags = -race
# #
# #
# Users should add `install` field to [gowork] to describe packages they want to # Users can also add `install` field to [gowork] to describe packages they want to
# be installed (+ automatically their dependencies are installed too). e.g. # be installed (+ automatically their dependencies are installed too). e.g.
# #
# [gowork] # [gowork]
...@@ -139,6 +139,9 @@ buildflags = ...@@ -139,6 +139,9 @@ buildflags =
# empty pkg-config path by default # empty pkg-config path by default
cpkgpath = cpkgpath =
# by default don't `go install` anything
install =
# everything is done by dependent parts # everything is done by dependent parts
recipe = plone.recipe.command recipe = plone.recipe.command
command = : command = :
...@@ -166,10 +169,10 @@ update-command = ${:command} ...@@ -166,10 +169,10 @@ update-command = ${:command}
stop-on-error = true stop-on-error = true
# install go packages # install go packages
# clients should put package list to install to gowork:install ("..." requests installing everything) # clients can put package list to install to gowork:install ("..." requests installing everything)
[gowork.goinstall] [gowork.goinstall]
recipe = plone.recipe.command recipe = plone.recipe.command
command = bash -c ". ${gowork:env.sh} && go install ${gowork:buildflags} -v $(echo -n '${gowork:install}' |tr '\n' ' ')" command = bash -c ". ${gowork:env.sh} && test -z '${gowork:install}' || go install ${gowork:buildflags} -v $(echo -n '${gowork:install}' |tr '\n' ' ')"
update-command = ${:command} update-command = ${:command}
stop-on-error = true stop-on-error = true
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment