diff --git a/.circleci/config.yml b/.circleci/config.yml index 9b9435f0e6..9039177964 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -12,14 +12,14 @@ jobs: - run: name: Go Tests command: make test-go - release-test: + test-release: docker: - image: circleci/golang:1.11.5 steps: - checkout - run: name: Version Test - command: if build/is-release-branch.sh $CIRCLE_BRANCH; then make find-missing-version; fi + command: make find-missing-version deploy: docker: - image: circleci/golang:1.11.5 @@ -37,11 +37,25 @@ workflows: build_and_test: jobs: - test - - release-test + - test-release: + filters: + branches: + only: + - /^[0-9]\.[0-9]$/ + - deploy-approval: + type: approval + requires: + - test + - test-release + filters: + branches: + only: + - /^[0-9]\.[0-9]$/ - deploy: requires: - - release-test - test + - test-release + - deploy-approval filters: branches: only: diff --git a/build/is-release-branch.sh b/build/is-release-branch.sh deleted file mode 100755 index 3f8c3c405d..0000000000 --- a/build/is-release-branch.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash - -# Copyright 2019 Cortex Labs, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -branch=$1 -if [[ $branch =~ ^[0-9]\.[0-9]$ ]]; then - exit 0; -fi -exit 1;