Skip to content

Commit cb8735e

Browse files
committed
Merge main into devex-sessions, resolved conflicts
2 parents aa53b54 + 38153e4 commit cb8735e

35 files changed

Lines changed: 2790 additions & 1110 deletions

.github/workflows/deploy.yml

Lines changed: 52 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,66 @@
1-
name: Deploy Docusaurus to GitHub Pages
1+
name: Deploy to GitHub Pages
2+
3+
defaults:
4+
run:
5+
shell: bash
6+
working-directory: ./website
27

38
on:
49
push:
510
branches:
6-
- main # Change to your default branch
11+
- main
12+
# Review gh actions docs if you want to further define triggers, paths, etc
13+
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
14+
15+
workflow_dispatch:
16+
17+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
18+
permissions:
19+
contents: read
20+
pages: write
21+
id-token: write
22+
23+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
24+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
25+
concurrency:
26+
group: "pages"
27+
cancel-in-progress: false
728

829
jobs:
9-
deploy:
30+
build:
31+
name: Build Docusaurus
1032
runs-on: ubuntu-latest
1133
steps:
12-
- name: Checkout repository
13-
uses: actions/checkout@v3
14-
15-
- name: Set up Node.js
16-
uses: actions/setup-node@v3
34+
- uses: actions/checkout@v4
1735
with:
18-
node-version: 20 # Use the Node.js version specified in your project
36+
fetch-depth: 0
37+
- uses: actions/setup-node@v4
38+
with:
39+
cache-dependency-path: ./website/package-lock.json
40+
node-version: 20
41+
cache: npm
1942

2043
- name: Install dependencies
21-
run: npm install
22-
working-directory: ./website # Change to your subfolder
23-
24-
- name: Build Docusaurus
44+
run: npm ci
45+
- name: Build website
2546
run: npm run build
26-
working-directory: ./website # Change to your subfolder
2747

28-
- name: Deploy to GitHub Pages
29-
uses: peaceiris/actions-gh-pages@v3
48+
- name: Upload Build Artifact
49+
uses: actions/upload-pages-artifact@v3
3050
with:
31-
github_token: ${{ secrets.GITHUB_TOKEN }}
32-
publish_dir: ./website/build # Path to the build folder
51+
path: ./website/build
52+
53+
deploy:
54+
name: Deploy to GitHub Pages
55+
needs: build
56+
57+
# Deploy to the github-pages environment
58+
environment:
59+
name: github-pages
60+
url: ${{ steps.deployment.outputs.page_url }}
61+
62+
runs-on: ubuntu-latest
63+
steps:
64+
- name: Deploy to GitHub Pages
65+
id: deployment
66+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,10 @@ dist
106106

107107
# Docusaurus cache and generated files
108108
.docusaurus
109+
build/
110+
website/build/
111+
contributor-beginner/
112+
contributor-beginner/build/
109113

110114
# Serverless directories
111115
.serverless/

0 commit comments

Comments
 (0)