From 0e101d534ec2b39abcf19f93fde1e67d651e4089 Mon Sep 17 00:00:00 2001 From: Romain Marcadier-Muller Date: Tue, 4 Jun 2019 16:11:15 +0200 Subject: [PATCH] chore: Fork Github PR builds to separate spec (#2740) Instead of trying to use one single spec that achieves both releasable builds as well as PR builds, use a different buildspec file for each, so the PR builds can be made more efficient. --- buildspec-pr.yaml | 11 +++++++++++ buildspec.yaml | 9 +++------ 2 files changed, 14 insertions(+), 6 deletions(-) create mode 100644 buildspec-pr.yaml diff --git a/buildspec-pr.yaml b/buildspec-pr.yaml new file mode 100644 index 0000000000000..909ff549172c7 --- /dev/null +++ b/buildspec-pr.yaml @@ -0,0 +1,11 @@ +version: 0.2 + +# This buildspec is intended to be used by GitHub PR builds. + +phases: + install: + commands: + - /bin/bash ./install.sh + build: + commands: + - /bin/bash ./build.sh diff --git a/buildspec.yaml b/buildspec.yaml index 97f31c3c91e31..ef888c6eb56b8 100644 --- a/buildspec.yaml +++ b/buildspec.yaml @@ -1,5 +1,7 @@ version: 0.2 +# This buildspec is intended to be run by CodePipeline builds. + phases: install: commands: @@ -12,12 +14,7 @@ phases: - /bin/bash ./build.sh post_build: commands: - - | - if [ -f .BUILD_COMPLETED ]; then - if [ -z \"${SKIP_PACK:-}\" ]; then - /bin/bash ./pack.sh - fi - fi + - "[ -f .BUILD_COMPLETED ] && /bin/bash ./pack.sh" artifacts: files: - "**/*"