This is an automated email from the ASF dual-hosted git repository.

tison pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/opendal.git


The following commit(s) were added to refs/heads/main by this push:
     new b8652548ad ci: fixup release nodejs and rc site (#4569)
b8652548ad is described below

commit b8652548ad240691adfc97a73d1f9effa60545fd
Author: tison <[email protected]>
AuthorDate: Thu May 2 16:43:27 2024 +0800

    ci: fixup release nodejs and rc site (#4569)
    
    Signed-off-by: tison <[email protected]>
---
 .github/workflows/ci_bindings_nodejs.yml | 4 +++-
 .github/workflows/docs.yml               | 9 ++++++++-
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/.github/workflows/ci_bindings_nodejs.yml 
b/.github/workflows/ci_bindings_nodejs.yml
index ab748f513c..460b7ac7b5 100644
--- a/.github/workflows/ci_bindings_nodejs.yml
+++ b/.github/workflows/ci_bindings_nodejs.yml
@@ -92,7 +92,7 @@ jobs:
               -e NAPI_TARGET=x86_64-unknown-linux-gnu \
               -w /build/bindings/nodejs \
               ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian \
-              bash -c "pnpm build"
+              bash -c "corepack enable && pnpm build"
               cd bindings/nodejs
               # change owner to current user
               sudo chown -R 1001:121 *.node
@@ -105,6 +105,7 @@ jobs:
               ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian-aarch64 \
               bash -c "set -e &&
               rustup target add aarch64-unknown-linux-gnu &&
+              corepack enable &&
               pnpm build --target aarch64-unknown-linux-gnu &&
               aarch64-unknown-linux-gnu-strip *.node"
               cd bindings/nodejs
@@ -119,6 +120,7 @@ jobs:
               ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-alpine \
               bash -c "set -e &&
               rustup target add aarch64-unknown-linux-musl &&
+              corepack enable &&
               pnpm build --target aarch64-unknown-linux-musl &&
               /aarch64-linux-musl-cross/bin/aarch64-linux-musl-strip *.node"
               cd bindings/nodejs
diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
index ead8f97250..194104ee4c 100644
--- a/.github/workflows/docs.yml
+++ b/.github/workflows/docs.yml
@@ -488,13 +488,20 @@ jobs:
           publish_dir: website/build
           publish_branch: site/main-staging
 
+      - name: Prepare rc staged name
+        if: ${{ startsWith(github.ref, 'refs/tags/') && contains(github.ref, 
'rc') }}
+        run: |
+          export OPENDAL_WEBSITE_STAGED_NAME=$(echo ${{ github.ref_name }} | 
sed 's/[.-]/_/g')
+          echo OPENDAL_WEBSITE_STAGED_NAME=${OPENDAL_WEBSITE_STAGED_NAME}
+          echo OPENDAL_WEBSITE_STAGED_NAME=${OPENDAL_WEBSITE_STAGED_NAME} >> 
$GITHUB_ENV
+
       - name: Deploy to rc staged
         uses: peaceiris/[email protected]
         if: ${{ startsWith(github.ref, 'refs/tags/') && contains(github.ref, 
'rc') }}
         with:
           github_token: ${{ secrets.GITHUB_TOKEN }}
           publish_dir: website/build
-          publish_branch: site/${{ github.ref_name }}-staging
+          publish_branch: site/${{ env.OPENDAL_WEBSITE_STAGED_NAME }}-staging
 
       - name: Clear build
         run: rm -rf ./website/build

Reply via email to