From 263d0e722470a821b416001d55cd3502d1b1edd7 Mon Sep 17 00:00:00 2001 From: Nick Lynch Date: Wed, 13 Oct 2021 18:39:08 +0100 Subject: [PATCH] chore: only run release-notes if BUMP_CANDIDATE is false (#16956) The release-notes script generates a RELEASE_NOTES file based on the current version and current changelog. During a BUMP_CANDIDATE build, a new version number has been generated, but no corresponding changelog has been created/updated. This causes the release notes to fail (and currently breaks the pipeline). Simplest fix is to skip release notes generation for these builds. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license* --- build.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index 3bc3228a193f7..aae39e94ea730 100755 --- a/build.sh +++ b/build.sh @@ -94,6 +94,10 @@ if [ "$check_compat" == "true" ]; then fi # Create the release notes for the current version. These are ephemeral and not saved in source. -node ./scripts/create-release-notes.js +# Skip this step for a "bump candidate" build, where a new, fake version number has been created +# without any corresponding changelog entries. +if ! ${BUMP_CANDIDATE:-false}; then + node ./scripts/create-release-notes.js +fi touch $BUILD_INDICATOR