From c315b363c5bf4740fcd9eb7d48c6afb2e7fa2740 Mon Sep 17 00:00:00 2001 From: Sasha <118575614+weboko@users.noreply.github.com> Date: Mon, 17 Mar 2025 09:57:16 +0100 Subject: [PATCH] chore: update ci npm command (#2304) --- .github/actions/npm/action.yml | 12 +++--------- ci/publish.js | 8 ++++++-- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/.github/actions/npm/action.yml b/.github/actions/npm/action.yml index a886a73ad6..411bc0e5b0 100644 --- a/.github/actions/npm/action.yml +++ b/.github/actions/npm/action.yml @@ -6,15 +6,9 @@ runs: - run: echo "$GITHUB_CONTEXT" shell: bash env: - GITHUB_CONTEXT: ${{ toJson(github) }} + GITHUB_CONTEXT: ${{ toJson(github) }} - run: npm i shell: bash - if: ${{ contains(' - refs/heads/master - refs/heads/release-please--branches--master - ', github.ref) }} + if: ${{ contains('refs/heads/master refs/heads/release-please--branches--master', github.ref) }} - uses: bahmutov/npm-install@v1 - if: ${{ contains(' - refs/heads/master - refs/heads/release-please--branches--master - ', github.ref) == false }} + if: ${{ !contains('refs/heads/master refs/heads/release-please--branches--master', github.ref) }} diff --git a/ci/publish.js b/ci/publish.js index 9fc5f288bd..30344b86b9 100644 --- a/ci/publish.js +++ b/ci/publish.js @@ -123,7 +123,7 @@ async function makeReleaseCandidate() { `npm version prerelease --preid $(git rev-parse --short HEAD) --workspaces true` ); } catch (e) { - console.error("Failed to mark release candidate versions.", e); + console.error("Failed to mark release candidate versions."); } } @@ -147,7 +147,7 @@ async function upgradeWakuDependencies(workspaces) { return acc; }, {}); const packageNames = Object.keys(map); - workspaces.forEach(async (info) => { + const promises = workspaces.map(async (info) => { if (info.private) { return; } @@ -171,4 +171,8 @@ async function upgradeWakuDependencies(workspaces) { ); } }); + + for (const promise of promises) { + await promise; + } }