Skip to content
This repository was archived by the owner on Sep 17, 2022. It is now read-only.

Commit 03d2d9d

Browse files
committed
Fix github action for deployment
1 parent 6f58104 commit 03d2d9d

File tree

4 files changed

+3
-33
lines changed

4 files changed

+3
-33
lines changed

.github/workflows/release.yml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,6 @@ jobs:
2222
make test/ci
2323
2424
- name: Release CLI executables
25-
env:
26-
GITHUB_TOKEN: ${{ secrets.GORELEASER_GITHUB_TOKEN }}
27-
DOCKER_HUB_USERNAME: getapid
28-
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }}
2925
run: |
3026
curl -sfL https://install.goreleaser.com/github.com/goreleaser/goreleaser.sh | sh
31-
docker login --username $DOCKER_HUB_USERNAME --password $DOCKER_HUB_PASSWORD
32-
PATH=$PATH:./bin/ make release
27+
PATH=$PATH:./bin/ goreleaser release

.github/workflows/test.yml

Lines changed: 0 additions & 19 deletions
This file was deleted.

Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@ all: test
77
build:
88
go build $(GOFLAGS) -o $(BIN) main.go
99

10-
release:
11-
goreleaser release
12-
1310
test: test/positive test/negative
1411

1512
test/ci:

template/template.go

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ import (
66
"strings"
77

88
"github.com/getapid/apid/log"
9-
"github.com/tidwall/gjson"
10-
119
"github.com/getapid/apid/variables"
10+
"github.com/tidwall/gjson"
1211
"go.uber.org/multierr"
1312
)
1413

@@ -23,7 +22,7 @@ func Render(template string, data variables.Variables) (string, error) {
2322
case tokenError:
2423
multiErr = multierr.Append(multiErr, fmt.Errorf("parsing error: %v : %v", template, token.val))
2524
case tokenEnd:
26-
goto EXIT
25+
return renderer.String(), multiErr
2726
case tokenText:
2827
if _, err := renderer.WriteString(token.val); err != nil {
2928
multiErr = multierr.Append(multiErr, fmt.Errorf("write string: %v : %v", template, err))
@@ -42,6 +41,4 @@ func Render(template string, data variables.Variables) (string, error) {
4241
renderer.WriteString(val.String())
4342
}
4443
}
45-
EXIT:
46-
return renderer.String(), multiErr
4744
}

0 commit comments

Comments
 (0)