diff --git a/.github/workflows/cd-docs.yml b/.github/workflows/cd-docs.yml new file mode 100644 index 00000000..1ff7c4fc --- /dev/null +++ b/.github/workflows/cd-docs.yml @@ -0,0 +1,14 @@ +name: "Run Docs CD" + +on: + push: + branches: + - "main" + +jobs: + build-deploy-docs: + uses: ./.github/workflows/docs.yml + with: + deploy: true + permissions: + contents: write diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 7c92d381..9a2bf714 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -10,12 +10,6 @@ env: jobs: code-checks: uses: ./.github/workflows/checks.yml - build-deploy-docs: - uses: ./.github/workflows/docs.yml - with: - deploy: true - permissions: - contents: write pre-release-check: runs-on: ubuntu-latest outputs: diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml new file mode 100644 index 00000000..6e9134d5 --- /dev/null +++ b/.github/workflows/ci-docs.yml @@ -0,0 +1,16 @@ +name: "Run Docs CI" + +on: + pull_request: + types: [opened, reopened, synchronize] + push: + branches: + - "**" + - "!gh-pages" + +jobs: + build-docs: + if: ${{ github.event_name == 'push' || (github.event.pull_request.head.repo.full_name != 'DS4SD/docling' && github.event.pull_request.head.repo.full_name != 'ds4sd/docling') }} + uses: ./.github/workflows/docs.yml + with: + deploy: false diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aec5d34d..e2b21ed2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,7 @@ on: push: branches: - "**" + - "!main" - "!gh-pages" env: @@ -16,8 +17,3 @@ jobs: code-checks: if: ${{ github.event_name == 'push' || (github.event.pull_request.head.repo.full_name != 'DS4SD/docling' && github.event.pull_request.head.repo.full_name != 'ds4sd/docling') }} uses: ./.github/workflows/checks.yml - build-docs: - if: ${{ github.event_name == 'push' || (github.event.pull_request.head.repo.full_name != 'DS4SD/docling' && github.event.pull_request.head.repo.full_name != 'ds4sd/docling') }} - uses: ./.github/workflows/docs.yml - with: - deploy: false