mirror of
https://github.com/godotengine/godot-team-reports.git
synced 2025-12-31 13:48:17 +03:00
CI: Check data.json exists before deploying page (#21)
This commit is contained in:
11
.github/workflows/ci.yml
vendored
11
.github/workflows/ci.yml
vendored
@@ -39,13 +39,24 @@ jobs:
|
|||||||
GRAPHQL_TOKEN: ${{ secrets.GRAPHQL_TOKEN }}
|
GRAPHQL_TOKEN: ${{ secrets.GRAPHQL_TOKEN }}
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Check that data.json was created
|
||||||
|
id: check_data
|
||||||
|
run: |
|
||||||
|
if [ -f "out/data.json" ]; then
|
||||||
|
echo "exists=true" >> $GITHUB_OUTPUT
|
||||||
|
else
|
||||||
|
echo "exists=false" >> $GITHUB_OUTPUT
|
||||||
|
fi
|
||||||
|
|
||||||
- name: Archive production artifacts
|
- name: Archive production artifacts
|
||||||
|
if: steps.check_data.outputs.exists == 'true'
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: web-static
|
name: web-static
|
||||||
path: out
|
path: out
|
||||||
|
|
||||||
- name: Deploy to GitHub Pages 🚀
|
- name: Deploy to GitHub Pages 🚀
|
||||||
|
if: steps.check_data.outputs.exists == 'true'
|
||||||
uses: JamesIves/github-pages-deploy-action@v4
|
uses: JamesIves/github-pages-deploy-action@v4
|
||||||
with:
|
with:
|
||||||
branch: gh-pages
|
branch: gh-pages
|
||||||
|
|||||||
Reference in New Issue
Block a user