File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change 14
14
paths :
15
15
- ' docs/**'
16
16
17
+ env :
18
+ RTDS_ADS_PROJECT : https://readthedocs.org/api/v3/projects/accelerated-data-science
19
+ RTDS_ADS_TOKEN : ${{ secrets.RTDS_ADS_TOKEN }}
20
+
17
21
jobs :
18
22
build-n-publish :
19
23
name : Build and publish Docs 📖 to Readthedocs
20
24
runs-on : ubuntu-latest
21
25
22
26
steps :
23
27
- name : When PR ✅ merged - Trigger Readthedocs build
24
- if : github.event.pull_request.merged == true
25
- env :
26
- RTDS_ADS_PROJECT : https://readthedocs.org/api/v3/projects/accelerated-data-science
27
- RTDS_ADS_TOKEN : ${{ secrets.RTDS_ADS_TOKEN }}
28
+ if : github.event_name == 'pull_request_target' && github.event.pull_request.merged == true
28
29
run : |
29
30
curl \
30
31
-X POST \
31
32
-H "Authorization: Token $RTDS_ADS_TOKEN" $RTDS_ADS_PROJECT/versions/latest/builds/
32
33
- name : When tag 🏷️ pushed - Trigger Readthedocs build
33
- if : github.event_name != 'pull_request'
34
- env :
35
- RTDS_ADS_PROJECT : https://readthedocs.org/api/v3/projects/accelerated-data-science
36
- RTDS_ADS_TOKEN : ${{ secrets.RTDS_ADS_TOKEN }}
34
+ if : github.event_name == 'push' && startsWith(github.ref_name, 'v')
37
35
run : |
38
36
curl \
39
37
-X POST \
You can’t perform that action at this time.
0 commit comments