diff --git a/.circleci/config.yml b/.circleci/config.yml index 19d4d332027a..747961f543a9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -878,9 +878,13 @@ jobs: name: "Require released code" command: | LAST_TAG="aztec-packages-v$(jq -r '.["."]' .release-please-manifest.json)" - git ls-remote --tags origin | grep -q "$LAST_TAG" && echo "Using code released from $LAST_TAG" || { echo "Skipping as $LAST_TAG is not yet published" && exit 0; } - echo "INCLUDE_RELEASED_CODE=1" >> docs/.env - git fetch origin --refetch --no-filter refs/tags/$LAST_TAG:refs/tags/$LAST_TAG + if git ls-remote --tags origin | grep "$LAST_TAG" > /dev/null; then + echo "Using code released from $LAST_TAG" + echo "INCLUDE_RELEASED_CODE=1" >> docs/.env + git fetch origin --refetch --no-filter refs/tags/$LAST_TAG:refs/tags/$LAST_TAG + else + echo "Skipping as $LAST_TAG is not yet published" + fi - run: name: "Build docs" command: build docs