Quellcode durchsuchen

Revert "ci: move docs deploy logic out of build script (#9108)" (#9120)

This reverts commit 1dcfb9a0c4599892f395765c99eab3a92467d2b0.
Yihau Chen vor 4 Tagen
Ursprung
Commit
82c0abd0d2
3 geänderte Dateien mit 12 neuen und 23 gelöschten Zeilen
  1. 0 6
      .github/workflows/docs.yml
  2. 12 0
      docs/build.sh
  3. 0 17
      docs/deploy.sh

+ 0 - 6
.github/workflows/docs.yml

@@ -89,12 +89,6 @@ jobs:
         run: |
           npm install
           ./build.sh
-
-      - name: Deploy
-        if: ${{ github.event_name == 'push' }}
-        working-directory: docs
-        run: |
-          ./deploy.sh
         env:
           VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
           VERCEL_SCOPE: ${{ secrets.VERCEL_SCOPE }}

+ 12 - 0
docs/build.sh

@@ -15,3 +15,15 @@ source ../ci/rust-version.sh
 # Build from /src into /build
 npm run build
 echo $?
+
+# Publish only from merge commits and beta release tags
+if [[ -n $CI ]]; then
+  if [[ -z $CI_PULL_REQUEST ]]; then
+    eval "$(../ci/channel-info.sh)"
+    if [[ -n $CI_TAG ]] && [[ $CI_TAG != $BETA_CHANNEL* ]]; then
+      echo "not a beta tag"
+      exit 0
+    fi
+    ./publish-docs.sh
+  fi
+fi

+ 0 - 17
docs/deploy.sh

@@ -1,17 +0,0 @@
-#!/usr/bin/env bash
-
-set -euo pipefail
-
-cd "$(dirname "$0")"
-
-# Publish only from merge commits and beta release tags
-if [[ -n $CI ]]; then
-  if [[ -z $CI_PULL_REQUEST ]]; then
-    eval "$(../ci/channel-info.sh)"
-    if [[ -n $CI_TAG ]] && [[ $CI_TAG != $BETA_CHANNEL* ]]; then
-      echo "not a beta tag"
-      exit 0
-    fi
-    ./publish-docs.sh
-  fi
-fi