From 12d73ee290d72a46feb9458c901923d3ad0d0bc4 Mon Sep 17 00:00:00 2001 From: Brooooooklyn Date: Tue, 3 Sep 2024 07:09:03 +0000 Subject: [PATCH] ci: handle the blocksuite commit is not found on current branch (#8061) --- .github/workflows/deploy.yml | 3 +++ tools/changelog/index.js | 6 ++++++ 2 files changed, 9 insertions(+) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 75d5d07b8d..e00a266489 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -276,6 +276,9 @@ jobs: deploy-done: needs: - output-prev-version + - build-web + - build-admin + - build-mobile - build-frontend-image - build-server-image - deploy diff --git a/tools/changelog/index.js b/tools/changelog/index.js index 8431315674..44b83edb18 100644 --- a/tools/changelog/index.js +++ b/tools/changelog/index.js @@ -49,6 +49,12 @@ async function getChangeLog(repo, previousCommit, currentCommit) { if (currentCommit) { const commit = repo.findCommit(currentCommit); + if (!commit) { + console.log( + `Current commit ${currentCommit} not found in ${repo.path()}` + ); + return ''; + } revWalk.push(commit.id()); } else { revWalk.pushHead();