-
Notifications
You must be signed in to change notification settings - Fork 27
57 lines (49 loc) · 1.63 KB
/
Copy pathpages.yml
File metadata and controls
57 lines (49 loc) · 1.63 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
name: Deploy Pages
on:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
concurrency:
group: pages
cancel-in-progress: true
jobs:
# the playground is the org site, served at https://speed-highlight.github.io
#
# needs, one time: a repo named speed-highlight.github.io (pages source
# "deploy from branch" main), a write deploy key on it, and its private
# key as the SITE_DEPLOY_KEY secret of this repo
deploy-site:
name: deploy speed-highlight.github.io
runs-on: ubuntu-latest
steps:
- name: Setup Repo
uses: actions/checkout@v6
- name: Setup Node
uses: actions/setup-node@v6
with:
node-version: lts/*
cache: npm
cache-dependency-path: |
package-lock.json
playground/package-lock.json
# the playground resolves the library through `file:..`, so it compiles
# against dist. Build it here instead of trusting the commit: the release
# workflow rebuilds and commits dist in parallel with this one, and its
# push cannot trigger a rerun, so a stale dist would ship silently
- run: npm clean-install
- run: npm run build
- run: npm clean-install
working-directory: playground
- run: npm run build
working-directory: playground
- name: Push to site repository
uses: peaceiris/actions-gh-pages@v4
with:
deploy_key: ${{ secrets.SITE_DEPLOY_KEY }}
external_repository: speed-highlight/speed-highlight.github.io
publish_branch: main
publish_dir: playground/dist
force_orphan: true