34
34
runs-on : ubuntu-latest
35
35
steps :
36
36
- name : Checkout
37
- uses : actions/checkout@v3
37
+ uses : actions/checkout@v4
38
+
38
39
- name : Detect package manager
39
40
id : detect-package-manager
40
41
run : |
@@ -49,24 +50,21 @@ jobs:
49
50
echo "runner=npx --no-install" >> $GITHUB_OUTPUT
50
51
exit 0
51
52
else
52
- echo "Unable to determine packager manager"
53
+ echo "Unable to determine package manager"
53
54
exit 1
54
55
fi
56
+
55
57
- name : Setup Node
56
- uses : actions/setup-node@v3
58
+ uses : actions/setup-node@v4
57
59
with :
58
60
node-version : " 20"
59
61
cache : ${{ steps.detect-package-manager.outputs.manager }}
62
+
60
63
- name : Setup Pages
61
- uses : actions/configure-pages@v2
62
- with :
63
- # Automatically inject basePath in your Next.js configuration file and disable
64
- # server side image optimization (https://nextjs.org/docs/api-reference/next/image#unoptimized).
65
- #
66
- # You may remove this line if you want to manage the configuration yourself.
67
- static_site_generator : next
64
+ uses : actions/configure-pages@v4
65
+
68
66
- name : Restore cache
69
- uses : actions/cache@v3
67
+ uses : actions/cache@v4
70
68
with :
71
69
path : |
72
70
.next/cache
@@ -75,15 +73,15 @@ jobs:
75
73
# If source files changed but packages didn't, rebuild from a prior cache.
76
74
restore-keys : |
77
75
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}-
76
+
78
77
- name : Install dependencies
79
78
run : ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
80
79
81
80
- name : Build with Next.js
82
81
run : ${{ steps.detect-package-manager.outputs.runner }} next build
83
- - name : Static HTML export with Next.js
84
- run : ${{ steps.detect-package-manager.outputs.runner }} next export
82
+
85
83
- name : Upload artifact
86
- uses : actions/upload-pages-artifact@v1
84
+ uses : actions/upload-pages-artifact@v3
87
85
with :
88
86
path : ./out
89
87
97
95
steps :
98
96
- name : Deploy to GitHub Pages
99
97
id : deployment
100
- uses : actions/deploy-pages@v1
98
+ uses : actions/deploy-pages@v4
0 commit comments