From c06671705d7703041536dcf2eb50c71507e4d63b Mon Sep 17 00:00:00 2001 From: xmik Date: Sun, 20 Feb 2022 01:25:29 +0000 Subject: [PATCH] fix github release --- .circleci/config.yml | 12 ++++++++++++ tasks | 8 +++++--- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7baf581..85056d3 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -31,6 +31,12 @@ workflows: filters: branches: only: master + - homebrew_tap: + requires: + - release + filters: + branches: + only: master jobs: build_unit: @@ -124,6 +130,12 @@ jobs: command: /bin/bash -c "./tasks release" - run: command: /bin/bash -c "./tasks release_gh" + homebrew_tap: + executor: platform + steps: + - setup + - attach_workspace: + at: ~/repo - run: command: /bin/bash -c "./tasks homebrew_tap" diff --git a/tasks b/tasks index 31867f3..d5f423b 100755 --- a/tasks +++ b/tasks @@ -1,7 +1,7 @@ #!/bin/bash set -Ee -RELEASER_VERSION="2.1.0" +RELEASER_VERSION="2.1.3" RELEASER_FILE="ops/releaser-${RELEASER_VERSION}" mkdir -p ops @@ -126,26 +126,28 @@ const DojoVersion = \"${next_version}\" echo "Releasing version ${VERSION}" GH_USER=kudulab + echo "Creating a GitHub release" $GHRELEASE_BIN release \ --user $GH_USER \ --repo dojo \ --tag $VERSION \ --name $VERSION \ --description "$(./tasks generate_release_notes ${VERSION})" - + echo "Uploading assets (1/2)" $GHRELEASE_BIN upload \ --user $GH_USER \ --repo dojo \ --tag $VERSION \ --name "dojo_linux_amd64" \ --file bin/dojo_linux_amd64 - + echo "Uploading assets (2/2)" $GHRELEASE_BIN upload \ --user $GH_USER \ --repo dojo \ --tag $VERSION \ --name "dojo_darwin_amd64" \ --file bin/dojo_darwin_amd64 + echo "Success" ;; homebrew_tap) if [ ! -f bin/dojo_darwin_amd64 ]; then echo "dojo_darwin_amd64 binary does not exist"; exit 1; fi