86
86
with :
87
87
category : " /language:${{matrix.language}}"
88
88
89
- - if : github.ref == 'refs/heads/dev/milesp/doc-site-from-branch'
90
- name : Check for Changes in main
91
- id : check_main_changed
92
- run : |
93
- git fetch origin dev/milesp/doc-site-from-branch
94
- if [[ $(git rev-list -n 1 HEAD) == $(git rev-list -n 1 origin/dev/milesp/doc-site-from-branch) ]]; then
95
- echo "No changes in main"
96
- echo "deploy_docs_site=false" >> $GITHUB_ENV
97
- else
98
- echo "Changes detected in main"
99
- echo "deploy_docs_site=true" >> $GITHUB_ENV
100
- - if : github.ref == 'refs/heads/dev/milesp/doc-site-from-branch'
101
- name : Export Main Changed Status
102
- run : |
103
- echo "Main changed status: $deploy_docs_site"
104
- env :
105
- deploy_docs_site : ${{ steps.check_main_changed.outputs.deploy_docs_site }}
106
-
107
- - if : github.ref == 'refs/heads/dev/milesp/doc-site-from-branch' && matrix.language == 'c-cpp' && env.deploy_docs_site == 'true'
89
+ - if : matrix.language == 'c-cpp' && github.event_name == 'push'
108
90
name : Clean up Sphinx Build Directory
109
91
run : |
110
92
find build/docs/sphinx -name '*.doctree' -delete
@@ -113,11 +95,11 @@ jobs:
113
95
find build/docs/sphinx -name '*.inv' -delete
114
96
find build/docs/sphinx -name '*.gz' -delete
115
97
116
- - if : github.ref == 'refs/heads/dev/milesp/doc-site-from-branch' && matrix.language == 'c-cpp' && env.deploy_docs_site == 'true '
98
+ - if : matrix.language == 'c-cpp' && github.event_name == 'push '
117
99
name : Create .nojekyll file
118
100
run : touch build/docs/sphinx/.nojekyll
119
-
120
- - if : github.ref == 'refs/heads/dev/milesp/doc-site-from-branch' && matrix.language == 'c-cpp' && env.deploy_docs_site == 'true '
101
+
102
+ - if : matrix.language == 'c-cpp' && github.event_name == 'push '
121
103
name : Deploy to GitHub Pages
122
104
uses : JamesIves/github-pages-deploy-action@v4
123
105
with :
0 commit comments