-
Notifications
You must be signed in to change notification settings - Fork 24
48 lines (40 loc) · 1.09 KB
/
Copy pathdeploy.yml
File metadata and controls
48 lines (40 loc) · 1.09 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
name: gh-pages
on:
push:
branches:
- master
jobs:
deploy:
strategy:
matrix:
os: [ubuntu-latest]
node: [14.x]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- name: Setup Node.js ${{ matrix.node }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- name: Install PNPM
uses: pnpm/action-setup@v1.2.1
with:
version: 5.x.x
- name: Cache NPM packages
id: npm-packages-cache
uses: actions/cache@v2
with:
path: node_modules
key: ${{ runner.os }}-npm-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-npm-
- name: Install dependencies
if: steps.npm-packages-cache.outputs.cache-hit != 'true'
run: pnpm install
- name: Build the package
run: pnpm run build
- name: Deploy to github pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build