-
Notifications
You must be signed in to change notification settings - Fork 2
48 lines (44 loc) · 1.14 KB
/
deploy-all.yml
File metadata and controls
48 lines (44 loc) · 1.14 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: deploy-all
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: '10.x'
registry-url: 'https://registry.npmjs.org'
- name: install yarn
run: npm install -g yarn
- name: load dependencies
run: yarn install
- name: build engine
run: yarn build
env:
PUBLIC_URL: https://team-stargarden.github.io/crosstoria-frontend/
- name: build storybook
run: yarn build-storybook
- name: create gh-pages
run: mkdir gh-pages
- name: move react build for deployment
run: |
mv build/* gh-pages/
- name: move storybook for deployment
run: cp -r storybook-build gh-pages/storybook
- name: GitHub Pages Deploy
if: success()
uses: crazy-max/ghaction-github-pages@v1
with:
target_branch: gh-pages
build_dir: gh-pages
keep_history: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_PAT: ${{ secrets.GITHUB_PAT }}