From 14006f162fc729c47cdf4dcacd1e2e30f5e7cf27 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 10:55:14 -0800 Subject: [PATCH 1/7] add approval --- .circleci/config.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9b9435f0e6..53d8a3eb16 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -38,10 +38,21 @@ workflows: jobs: - test - release-test + - deploy-approval: + type: approval + requires: + - test + - release-test + # filters: + # branches: + # only: + # - /^[0-9]\.[0-9]$/ + # - master - deploy: requires: - release-test - test + - deploy-approval filters: branches: only: From 3139b85bc3e846793607188ed0a725ad77291683 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 11:00:11 -0800 Subject: [PATCH 2/7] Add approval filter --- .circleci/config.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 53d8a3eb16..f59b177eaf 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -43,11 +43,11 @@ workflows: requires: - test - release-test - # filters: - # branches: - # only: - # - /^[0-9]\.[0-9]$/ - # - master + filters: + branches: + only: + - /^[0-9]\.[0-9]$/ + - master - deploy: requires: - release-test From de4317547c06a69d0c4dd27023e5750825b3f642 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 11:03:52 -0800 Subject: [PATCH 3/7] Remove deploy filter --- .circleci/config.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index f59b177eaf..ed13fb1c87 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -53,8 +53,8 @@ workflows: - release-test - test - deploy-approval - filters: - branches: - only: - - /^[0-9]\.[0-9]$/ - - master + # filters: + # branches: + # only: + # - /^[0-9]\.[0-9]$/ + # - master From ec9f240c908aa9c61e8b3beb064cc42fbfd07f05 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 11:10:23 -0800 Subject: [PATCH 4/7] Add filter to release-test --- .circleci/config.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ed13fb1c87..c29ee3d20b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -19,7 +19,7 @@ jobs: - 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,7 +37,11 @@ workflows: build_and_test: jobs: - test - - release-test + - release-test: + filters: + branches: + only: + - /^[0-9]\.[0-9]$/ - deploy-approval: type: approval requires: @@ -47,11 +51,10 @@ workflows: branches: only: - /^[0-9]\.[0-9]$/ - - master - deploy: requires: - - release-test - test + - release-test - deploy-approval # filters: # branches: From 1aa8cb61e7c516e6ff29c0aba27254589250a661 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 11:13:12 -0800 Subject: [PATCH 5/7] Add deploy filters --- .circleci/config.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c29ee3d20b..f9100401e4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -56,8 +56,8 @@ workflows: - test - release-test - deploy-approval - # filters: - # branches: - # only: - # - /^[0-9]\.[0-9]$/ - # - master + filters: + branches: + only: + - /^[0-9]\.[0-9]$/ + - master From 232cac9b0c3c40609a812a485fde981928e20a59 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 11:16:55 -0800 Subject: [PATCH 6/7] Rename release-test to test-release --- .circleci/config.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index f9100401e4..9039177964 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -12,7 +12,7 @@ jobs: - run: name: Go Tests command: make test-go - release-test: + test-release: docker: - image: circleci/golang:1.11.5 steps: @@ -37,7 +37,7 @@ workflows: build_and_test: jobs: - test - - release-test: + - test-release: filters: branches: only: @@ -46,7 +46,7 @@ workflows: type: approval requires: - test - - release-test + - test-release filters: branches: only: @@ -54,7 +54,7 @@ workflows: - deploy: requires: - test - - release-test + - test-release - deploy-approval filters: branches: From 13602f7c12932001fa87dc5b6b45847fe361cf46 Mon Sep 17 00:00:00 2001 From: David Eliahu Date: Fri, 22 Feb 2019 11:19:28 -0800 Subject: [PATCH 7/7] Delete is-release-branch.sh --- build/is-release-branch.sh | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100755 build/is-release-branch.sh 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;