1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-03-17 20:47:50 +02:00
This commit is contained in:
Carlos Alexandro Becker 2016-12-28 23:46:18 -02:00
parent e4449c6c0b
commit e0300e5d80
No known key found for this signature in database
GPG Key ID: E61E2F7DC14AB940
2 changed files with 6 additions and 3 deletions

View File

@ -6,6 +6,7 @@ import (
"os"
yaml "gopkg.in/yaml.v1"
"fmt"
)
var emptyBrew = HomebrewDeploy{}
@ -36,12 +37,14 @@ func Load(file string) (config ProjectConfig, err error) {
return config, err
}
err = yaml.Unmarshal(data, &config)
fmt.Println("a",config.BinaryName)
config = fix(config)
fmt.Println("b",config.BinaryName)
if config.BinaryName == "" {
return config, errors.New("Missing binary_name")
return config, errors.New("missing binary_name")
}
if config.Repo == "" {
return config, errors.New("Missing repo")
return config, errors.New("missing repo")
}
return config, err
}

View File

@ -16,7 +16,7 @@ var version = "none"
func main() {
config, err := config.Load("goreleaser.yml")
if err != nil {
log.Fatalln("Failed to load goreleaser.yml", err.Error())
log.Fatalln("Failed to load goreleaser.yml:", err.Error())
}
tag, err := git.CurrentTag()
if err != nil {