0
0
mirror of https://github.com/thegeeklab/wp-gitea-release.git synced 2024-11-28 08:20:34 +00:00

using StringSlice instead of []string for Files

This commit is contained in:
jackspirou 2016-01-15 16:02:12 -06:00
parent fcfb446e4c
commit d4f663cf8f
3 changed files with 4 additions and 4 deletions

View File

@ -13,8 +13,7 @@ Sample configuration:
publish:
github_release:
api_key: my_github_api_key
files:
- dist/*
files: dist/*
checksum: sha1
```
@ -26,6 +25,7 @@ publish:
api_key: my_github_api_key
files:
- dist/*
- bin/binary.exe
checksum:
- md5
- sha1

View File

@ -60,7 +60,7 @@ func main() {
}
var files []string
for _, glob := range vargs.Files {
for _, glob := range vargs.Files.Slice() {
globed, err := filepath.Glob(glob)
if err != nil {
fmt.Printf("Failed to glob %s\n", glob)

View File

@ -7,6 +7,6 @@ type Params struct {
BaseURL string `json:"base_url"`
UploadURL string `json:"upload_url"`
APIKey string `json:"api_key"`
Files []string `json:"files"`
Files drone.StringSlice `json:"files"`
Checksum drone.StringSlice `json:"checksum"`
}