File tree Expand file tree Collapse file tree 4 files changed +20
-0
lines changed
[% if repo_host_type == 'github.com' %].github[% endif %]/workflows Expand file tree Collapse file tree 4 files changed +20
-0
lines changed Original file line number Diff line number Diff line change 18
18
- .readthedocs.yaml
19
19
- README.md
20
20
- docs/**
21
+ - pdm.lock
21
22
permissions :
22
23
pull-requests : write
Original file line number Diff line number Diff line change 6
6
post_checkout :
7
7
- env | sort
8
8
- git fetch --unshallow || true
9
+ # Cancel building pull requests when there aren't changed in the related files and folders.
10
+ # If there are no changes (git diff exits with 0) we force the command to return with 183.
11
+ # This is a special exit code on Read the Docs that will cancel the build immediately.
12
+ # Ref: https://docs.readthedocs.io/en/stable/build-customization.html#cancel-build-based-on-a-condition
13
+ - |
14
+ if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/main -- .github/workflows/readthedocs-preview.yml .readthedocs.yaml README.md docs/ pdm.lock;
15
+ then
16
+ exit 183;
17
+ fi
9
18
post_install :
10
19
- python -m pip install --upgrade --no-cache-dir pdm
11
20
- PDM_NO_EDITABLE=true make dev-doc
Original file line number Diff line number Diff line change 6
6
post_checkout :
7
7
- env | sort
8
8
- git fetch --unshallow || true
9
+ # Cancel building pull requests when there aren't changed in the related files and folders.
10
+ # If there are no changes (git diff exits with 0) we force the command to return with 183.
11
+ # This is a special exit code on Read the Docs that will cancel the build immediately.
12
+ # Ref: https://docs.readthedocs.io/en/stable/build-customization.html#cancel-build-based-on-a-condition
13
+ - |
14
+ if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/main -- .github/workflows/readthedocs-preview.yml .readthedocs.yaml README.md docs/ pdm.lock;
15
+ then
16
+ exit 183;
17
+ fi
9
18
post_install :
10
19
- python -m pip install --upgrade --no-cache-dir pdm
11
20
- PDM_NO_EDITABLE=true make dev-doc
Original file line number Diff line number Diff line change 18
18
- .readthedocs.yaml
19
19
- README.md
20
20
- docs/**
21
+ - pdm.lock
21
22
permissions:
22
23
pull-requests: write
You can’t perform that action at this time.
0 commit comments