Skip to content

Commit e53c1c9

Browse files
committed
fixed Github Action deploy
1 parent 126a6a5 commit e53c1c9

File tree

1 file changed

+24
-22
lines changed

1 file changed

+24
-22
lines changed

.github/workflows/deploy.yml

Lines changed: 24 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
name: Deploy Next.js site to GitHub Pages
1+
name: Deploy to GitHub Pages
22

33
on:
44
push:
5-
branches:
6-
- main
5+
branches: ["main"]
6+
workflow_dispatch:
77

88
permissions:
99
contents: read
@@ -12,35 +12,37 @@ permissions:
1212

1313
concurrency:
1414
group: "pages"
15-
cancel-in-progress: true
15+
cancel-in-progress: false
1616

1717
jobs:
1818
build:
1919
runs-on: ubuntu-latest
20-
2120
steps:
22-
- uses: actions/checkout@v4
23-
24-
- uses: actions/setup-node@v4
21+
- name: Checkout
22+
uses: actions/checkout@v4
23+
- name: Setup Node
24+
uses: actions/setup-node@v4
2525
with:
26-
node-version: 18
27-
cache: npm
28-
29-
- run: npm ci
30-
- run: npm run build
31-
32-
- uses: actions/upload-pages-artifact@v3
26+
node-version: "20"
27+
cache: "npm"
28+
- name: Install dependencies
29+
run: npm ci
30+
- name: Build
31+
run: npm run build
32+
- name: Add .nojekyll
33+
run: touch out/.nojekyll
34+
- name: Upload artifact
35+
uses: actions/upload-pages-artifact@v3
3336
with:
34-
path: out
37+
path: ./out
3538

3639
deploy:
37-
needs: build
38-
runs-on: ubuntu-latest
39-
4040
environment:
4141
name: github-pages
4242
url: ${{ steps.deployment.outputs.page_url }}
43-
43+
runs-on: ubuntu-latest
44+
needs: build
4445
steps:
45-
- id: deployment
46-
uses: actions/deploy-pages@v4
46+
- name: Deploy to GitHub Pages
47+
id: deployment
48+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)