Skip to content

Commit cb4782f

Browse files
authored
Merge pull request #11 from vincentfretin/docs-ci
Full site build pipeline in GitHub Actions, replacing a-frobot
2 parents 4bfd980 + 8da4230 commit cb4782f

1 file changed

Lines changed: 23 additions & 2 deletions

File tree

‎.github/workflows/deploy-pages.yml‎

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ name: Deploy to GitHub Pages
33
on:
44
push:
55
branches: [master]
6+
repository_dispatch:
7+
types: [deploy]
8+
workflow_dispatch:
69

710
permissions:
811
contents: read
@@ -21,18 +24,36 @@ jobs:
2124
url: ${{ steps.deployment.outputs.page_url }}
2225
steps:
2326
- uses: actions/checkout@v6
27+
with:
28+
repository: aframevr/aframe-site
29+
path: aframe-site
2430

2531
- uses: actions/setup-node@v6
2632
with:
2733
node-version: 24
34+
cache: 'npm'
35+
cache-dependency-path: 'aframe-site/package-lock.json'
36+
37+
- name: Install dependencies
38+
run: npm ci --ignore-scripts --include=dev
39+
working-directory: aframe-site
40+
41+
- name: Build docs
42+
run: npm run bumpdocs
43+
working-directory: aframe-site
44+
45+
- name: Generate site
46+
run: npm run generate
47+
working-directory: aframe-site
2848

2949
- name: Generate Pagefind index
30-
run: npx pagefind@1.5.0 --site .
50+
run: npx pagefind --site public
51+
working-directory: aframe-site
3152

3253
- name: Upload Pages artifact
3354
uses: actions/upload-pages-artifact@v4
3455
with:
35-
path: .
56+
path: aframe-site/public
3657

3758
- name: Deploy to GitHub Pages
3859
id: deployment

0 commit comments

Comments
 (0)