Skip to content

Commit 410381b

Browse files
Add git pages build action
1 parent 3af91b1 commit 410381b

2 files changed

Lines changed: 33 additions & 0 deletions

File tree

.github/workflows/build.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: deploy
2+
on: [push]
3+
jobs:
4+
build:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- name: Checkout
8+
uses: actions/checkout@v2
9+
10+
- name: Node v16 Setup
11+
uses: actions/setup-node@v2
12+
with:
13+
node-version: 16
14+
15+
- name: Install dependencies
16+
run: npm install
17+
18+
- name: Build
19+
run: npm run build
20+
21+
- name: Static HTML Export
22+
run: npm run export
23+
24+
- name: Disable Jekyl # https://github.blog/2009-12-29-bypassing-jekyll-on-github-pages/
25+
run: touch ./out/.nojekyll
26+
27+
- name: Delpoy 🚀
28+
uses: JamesIves/[email protected]
29+
with:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
BRANCH: gh-pages
32+
FOLDER: out

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
"scripts": {
66
"dev": "next dev",
77
"build": "next build",
8+
"export": "next export",
89
"start": "next start",
910
"lint": "next lint"
1011
},

0 commit comments

Comments
 (0)