-
Notifications
You must be signed in to change notification settings - Fork 83
63 lines (53 loc) · 1.36 KB
/
deploy-docs.yml
File metadata and controls
63 lines (53 loc) · 1.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Deploy JSDoc to GitHub Pages
on:
push:
tags:
- 'docs-*'
workflow_dispatch:
inputs:
dry_run:
description: 'Build docs only (skip deploy to Pages)'
required: true
type: boolean
default: true
concurrency:
group: deploy-docs
cancel-in-progress: false
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
if: github.repository == 'RobotWebTools/rclnodejs'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
fetch-tags: true
- name: Fetch gh-pages branch
run: git fetch origin gh-pages:refs/remotes/origin/gh-pages
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 24.x
- name: Install dependencies
run: npm install --ignore-scripts --no-audit --no-fund
- name: Build docs
run: npm run docs:gh-pages
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v5
with:
path: build/gh-pages-docs
deploy:
needs: build
if: ${{ !(inputs.dry_run == true) }}
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v5