-
Notifications
You must be signed in to change notification settings - Fork 2
41 lines (34 loc) · 1.02 KB
/
deploy.yaml
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
name: deploy
on:
push:
branches:
- master
defaults:
run:
shell: bash
jobs:
deploy:
name: ${{ matrix.command }}
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Use Node.js 16
uses: actions/setup-node@v1
with:
node-version: 16
- run: yarn install
- name: Build core
run: yarn build
- name: Push build to gh-pages branch
run: |
git config --global user.name "desi-ivanov bot"
git config --global user.email "desi-ivanov-bot@users.noreply.github.com'"
git clone https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/desi-ivanov/cars-rl --depth 1 --branch gh-pages gh-pages
cd gh-pages
git rm -rf .
cp -r ../dist/* .
git add -A
git commit -m "Update gh-pages"
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/desi-ivanov/cars-rl
git push origin gh-pages