-
Notifications
You must be signed in to change notification settings - Fork 4
36 lines (36 loc) · 1.16 KB
/
build.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
name: Build and deploy to Github pages
on:
push:
branches:
- master
schedule:
# * is a special character in YAML so you have to quote this string
# Run at midnight every day (UTC)
- cron: "0 0 * * *"
workflow_dispatch:
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎️
uses: actions/checkout@v2 # If you're using actions/checkout@v2 you must set persist-credentials to false in most cases for the deployment to work correctly.
with:
persist-credentials: false
- name: Install and Build
run: |
npm install
npm run build
npm run export
npm run nojekyll
npm run cname
npm run copy-ratings
- name: Commit files
run: |
git config --local user.email ${{ secrets.ACTION_BUILD_EMAIL }}
git config --local user.name ${{ secrets.ACTION_BUILD_NAME }}
git add -A
git commit -m "Update page"
- name: Push changes
uses: ad-m/github-push-action@master # https://github.com/ad-m/github-push-action
with:
github_token: ${{ secrets.GITHUB_TOKEN }}