Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .github/labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,4 @@

- name: skip-doc
description: Skips the documentation build job in CI
color: e4e669

- name: skip-test
description: Skips the test job in CI
color: e4e669
22 changes: 21 additions & 1 deletion .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -672,6 +672,7 @@ jobs:

doc-build:
name: Documentation
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-doc') }}
runs-on: public-ubuntu-latest-16-cores
timeout-minutes: 30
container:
Expand Down Expand Up @@ -774,6 +775,25 @@ jobs:
path: doc/_build/html
retention-days: 7

doc-build-check:
name: Documentation check
runs-on: ubuntu-latest
needs: [doc-build]
if: always()
permissions:
contents: read
steps:
- name: Check doc-build result
env:
DOC_BUILD_RESULT: ${{ needs.doc-build.result }}
run: |
if [[ "${DOC_BUILD_RESULT}" == "success" || "${DOC_BUILD_RESULT}" == "skipped" ]]; then
echo "doc-build passed or skipped — OK"
else
echo "doc-build failed"
exit 1
fi

doc-deploy-pr:
name: "Deploy PR documentation"
runs-on: ubuntu-latest
Expand Down Expand Up @@ -894,7 +914,7 @@ jobs:

package:
name: Package library
needs: [smoke-tests, remote-connect, embedding-tests, embedding-scripts-tests, doc-build]
needs: [smoke-tests, remote-connect, embedding-tests, embedding-scripts-tests, doc-build-check]
runs-on: ubuntu-latest
permissions:
attestations: write # Required to generate package attestations for security
Expand Down
26 changes: 26 additions & 0 deletions .github/workflows/label-pre-commit-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Auto-label pre-commit CI PRs

on:
pull_request:
types: [opened]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions: {}

jobs:
auto-label:
name: Add skip-doc label to pre-commit CI PRs
runs-on: ubuntu-latest
if: github.event.pull_request.user.login == 'pre-commit-ci[bot]'
permissions:
pull-requests: write # Required to add labels to pull requests
steps:
- name: Add skip-doc label
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_NUMBER: ${{ github.event.pull_request.number }}
REPO: ${{ github.repository }}
run: gh pr edit "${PR_NUMBER}" --add-label "skip-doc" --repo "${REPO}"
1 change: 1 addition & 0 deletions doc/changelog.d/1566.test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Skip-doc label to skipping doc build
Loading