-
-
Notifications
You must be signed in to change notification settings - Fork 40
49 lines (41 loc) · 1.05 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
40
41
42
43
44
45
46
47
48
49
name: Build and Deploy
on:
push:
branches:
- main
pull_request:
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎️
uses: actions/checkout@v2
with:
persist-credentials: false
- uses: actions/setup-python@v2
with:
python-version: '3.8'
- uses: actions/setup-node@v2-beta
with:
node-version: '18'
- uses: actions/cache@v2
with:
path: |
~/.npm
key: ${{ runner.os }}-npm-${{ hashFiles('package.json') }}
- name: Install dependencies
run: |
pip install -r requirements.txt
npm install
npm install -g gatsby
- name: Build 🔧
run: |
make build
- name: Deploy 🚀
uses: JamesIves/github-pages-deploy-action@releases/v3
if: github.ref == 'refs/heads/main'
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
FOLDER: public
SINGLE_COMMIT: true