From 76615836831013e050b2ae0e469e7d6fa664d3ac Mon Sep 17 00:00:00 2001 From: Justin Date: Mon, 15 Sep 2025 14:26:21 +0800 Subject: [PATCH 1/2] add github flow --- .github/workflows/main.yml | 42 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..1f28850 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,42 @@ +# This is a basic workflow to help you get started with Actions + +name: CI + +# Controls when the workflow will run +on: + # Triggers the workflow on push events but only for the main branch + push: + branches: + - main + #- preview + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains jobs called "Build-main" and "Build-Preview" + Build-Main: + if: ${{ github.ref == 'refs/heads/main' }} + uses: dynamsoft-docs/Docs-Template-Repo/.github/workflows/called-workflow-build-sync-production.yml@main + with: + doc-repo: code-parser-docs-js + doc-url: code-parser/docs/web + secrets: inherit + + Build-Preview: + if: ${{ github.ref == 'refs/heads/preview' }} + uses: dynamsoft-docs/Docs-Template-Repo/.github/workflows/called-workflow-build-sync-testing.yml@preview + with: + doc-repo: code-parser-docs-js + doc-url: code-parser/docs/web + secrets: inherit + + Build-v2: + if: ${{ github.ref == 'refs/heads/v2' }} + uses: dynamsoft-docs/Docs-Template-Repo/.github/workflows/called-workflow-build-sync-testing.yml@DCV-v2 + with: + doc-repo: code-parser-docs-js + doc-url: code-parser/docs/v2/web + doc-branch: v2 + secrets: inherit From a3386afccbb8eb290b3716f9173c5821c9e09f5c Mon Sep 17 00:00:00 2001 From: Justin Date: Mon, 15 Sep 2025 14:47:32 +0800 Subject: [PATCH 2/2] update --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 1f28850..860602e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -34,7 +34,7 @@ jobs: Build-v2: if: ${{ github.ref == 'refs/heads/v2' }} - uses: dynamsoft-docs/Docs-Template-Repo/.github/workflows/called-workflow-build-sync-testing.yml@DCV-v2 + uses: dynamsoft-docs/Docs-Template-Repo/.github/workflows/called-workflow-build-sync-production.yml@DCV-v2 with: doc-repo: code-parser-docs-js doc-url: code-parser/docs/v2/web