File tree 1 file changed +15
-38
lines changed
1 file changed +15
-38
lines changed Original file line number Diff line number Diff line change 1
- name : Deploy Next.js site to Pages
1
+ name : Deploy to GitHub Pages
2
2
3
3
on :
4
4
push :
5
- branches : ["main"]
6
- workflow_dispatch :
7
-
8
- permissions :
9
- contents : read
10
- pages : write
11
- id-token : write
12
-
13
- concurrency :
14
- group : " pages"
15
- cancel-in-progress : true
5
+ branches : [ main ]
16
6
17
7
jobs :
18
- build :
8
+ build-and-deploy :
19
9
runs-on : ubuntu-latest
10
+
20
11
steps :
21
- - name : Checkout
22
- uses : actions/checkout@v4
23
-
24
- - name : Setup Node
12
+ - uses : actions/checkout@v4
13
+
14
+ - name : Setup Node.js
25
15
uses : actions/setup-node@v4
26
16
with :
27
- node-version : " 18"
28
-
29
- - name : Setup Pages
30
- uses : actions/configure-pages@v4
31
-
17
+ node-version : ' 18'
18
+
32
19
- name : Install dependencies
33
20
run : npm install
34
-
35
- - name : Build with Next.js
21
+
22
+ - name : Build
36
23
run : npm run build
37
-
38
- - name : Upload artifact
39
- uses : actions/upload-pages-artifact@v1
40
- with :
41
- path : ./out
42
24
43
- deploy :
44
- environment :
45
- name : github-pages
46
- url : ${{ steps.deployment.outputs.page_url }}
47
- runs-on : ubuntu-latest
48
- needs : build
49
- steps :
50
25
- name : Deploy to GitHub Pages
51
- id : deployment
52
- uses : actions/deploy-pages@v1
26
+ uses : peaceiris/actions-gh-pages@v3
27
+ with :
28
+ github_token : ${{ secrets.GITHUB_TOKEN }}
29
+ publish_dir : ./out
You can’t perform that action at this time.
0 commit comments