From a8b9b2b5e13c10dea802bfe1d85f78217e7186a8 Mon Sep 17 00:00:00 2001 From: liujuping Date: Tue, 16 Jan 2024 18:00:18 +0800 Subject: [PATCH] chore: add "set -e" in build.sh --- .github/workflows/pre build.yml | 34 +++++++++++++++++++++++++++++ packages/shell/src/api/commonUI.tsx | 2 +- scripts/build.sh | 2 ++ 3 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/pre build.yml diff --git a/.github/workflows/pre build.yml b/.github/workflows/pre build.yml new file mode 100644 index 000000000..e6f7d6479 --- /dev/null +++ b/.github/workflows/pre build.yml @@ -0,0 +1,34 @@ +name: Pre Build + +on: + push: + paths: + - 'packages/**' + - '!packages/**.md' + pull_request: + paths: + - 'packages/**' + - '!packages/**.md' + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Install dependencies and setup + run: npm install && npm run setup + + - name: Build + run: npm run build + + - name: Check build status + run: | + if [ $? -eq 0 ]; then + echo "Build succeeded!" + else + echo "Build failed!" + exit 1 + fi diff --git a/packages/shell/src/api/commonUI.tsx b/packages/shell/src/api/commonUI.tsx index 0a9021fe6..f25cd232c 100644 --- a/packages/shell/src/api/commonUI.tsx +++ b/packages/shell/src/api/commonUI.tsx @@ -23,7 +23,7 @@ export class CommonUI implements IPublicApiCommonUI { Form = Form; Icon = Icon; Input = Input; - Loading = Loading; + Loading = Loading as any; Message = Message; Overlay = Overlay; Pagination = Pagination; diff --git a/scripts/build.sh b/scripts/build.sh index 0d96598e6..828bb16d9 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -1,5 +1,7 @@ #!/usr/bin/env bash +set -e + lerna run build \ --scope @alilc/lowcode-types \ --scope @alilc/lowcode-utils \