-
-
Notifications
You must be signed in to change notification settings - Fork 504
39 lines (37 loc) · 1.09 KB
/
gh-pages.yml
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
name: Update GitHub pages
on:
release:
types: [published]
workflow_dispatch:
jobs:
run:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 7
- uses: actions/setup-node@v3
with:
node-version: 16
#cache: 'pnpm'
- name: Install packages
run: pnpm i
- name: Setup
run: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
- name: Build
run: pnpm build
- name: Copy build
run: |
rm -rf /tmp/gh-pages
mkdir /tmp/gh-pages
cp ./packages/examples/build/* /tmp/gh-pages/
mkdir /tmp/gh-pages/sandbox
cp -r ./packages/sandbox/dist/* /tmp/gh-pages/sandbox/
mkdir /tmp/gh-pages/sandbox_simple
cp -r ./packages/sandbox_simple/dist/* /tmp/gh-pages/sandbox_simple/
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: /tmp/gh-pages/