cmd/build: Now support package without version/selector

This commit is contained in:
Daniele Rondina
2019-12-27 12:19:03 +01:00
committed by Ettore Di Giacinto
parent 91d05b071d
commit a7e262cc48

View File

@@ -101,6 +101,11 @@ var buildCmd = &cobra.Command{
Fatal("Invalid package string ", a, ": ", err.Error())
}
if gp.Version == "" {
gp.Version = "0"
gp.Condition = _gentoo.PkgCondGreaterEqual
}
pack := &pkg.DefaultPackage{
Name: gp.Name,
Version: fmt.Sprintf("%s%s%s", gp.Condition.String(), gp.Version, gp.VersionSuffix),