Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,14 @@ jobs:
with:
node-version: 20

- name: Install yarn
run: npm install -g yarn

- name: Install dependencies
run: npm install
run: yarn install

- name: Build site
run: npm run build
run: yarn build

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
Expand Down
56 changes: 56 additions & 0 deletions .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Check Documentation Build

on:
pull_request:
branches:
- main
- gh-pages

jobs:
check-build:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: 20

- name: Install yarn
run: npm install -g yarn

- name: Install dependencies
run: yarn install

- name: Build site
run: yarn build

- name: Check build output
run: |
if [ ! -d "build" ]; then
echo "Build directory not found. Build failed."
exit 1
fi
echo "Build completed successfully!"

- name: Comment PR
uses: actions/github-script@v6
with:
script: |
const buildStatus = process.env.BUILD_STATUS === 'success' ? '✅' : '❌';
const message = `${buildStatus} Documentation build check completed.`;

github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: message
});
env:
BUILD_STATUS: ${{ job.status }}