Skip to content

Commit 00a88f2

Browse files
committed
Add release job
1 parent d996e19 commit 00a88f2

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.circleci/config.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,23 @@ jobs:
5757
path: /tmp/artifacts
5858
destination: source-tarball
5959

60+
publish-github-release:
61+
docker:
62+
- image: circleci/golang:1.16
63+
steps:
64+
- attach_workspace:
65+
at: /tmp/artifacts
66+
- run:
67+
name: "Extract version"
68+
command: |
69+
echo "export VERSION=${CIRCLE_TAG#offscreen-}" >> $BASH_ENV
70+
echo "Extracted version: ${CIRCLE_TAG#offscreen-}"
71+
- run:
72+
name: "Publish Release on GitHub"
73+
command: |
74+
go get github.com/tcnksm/ghr
75+
ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${VERSION} /tmp/artifacts/
76+
6077
filters: &filters
6178
tags:
6279
only: /^offscreen-.*/
@@ -73,3 +90,7 @@ workflows:
7390
filters: *filters
7491
requires:
7592
- cut-release
93+
- publish:
94+
filters: *filters
95+
requires:
96+
- calculate-checksum

0 commit comments

Comments
 (0)