Skip to content

Commit 3bf5ded

Browse files
committed
Updated github action
1 parent 35b1f92 commit 3bf5ded

File tree

1 file changed

+9
-28
lines changed

1 file changed

+9
-28
lines changed

.github/workflows/deploy.yml

+9-28
Original file line numberDiff line numberDiff line change
@@ -6,44 +6,25 @@ on:
66
- master
77

88
jobs:
9-
build:
10-
name: Build
9+
deploy:
1110
runs-on: ubuntu-latest
12-
1311
steps:
14-
- name: Checkout repo
12+
- name: Checkout code
1513
uses: actions/checkout@v3
1614

17-
- name: Setup Node
15+
- name: Set up Node.js
1816
uses: actions/setup-node@v3
17+
with:
18+
node-version: 20
1919

2020
- name: Install dependencies
21-
uses: bahmutov/npm-install@v1
22-
23-
- name: Build project
21+
run: npm install
22+
23+
- name: Build Project
2424
run: npm run build
2525

26-
- name: Upload production-ready build files
27-
uses: actions/upload-artifact@v3
28-
with:
29-
name: production-files
30-
path: ./dist
31-
32-
deploy:
33-
name: Deploy
34-
needs: build
35-
runs-on: ubuntu-latest
36-
if: github.ref == 'refs/heads/master'
37-
38-
steps:
39-
- name: Download artifact
40-
uses: actions/download-artifact@v3
41-
with:
42-
name: production-files
43-
path: ./dist
44-
4526
- name: Deploy to GitHub Pages
4627
uses: peaceiris/actions-gh-pages@v3
4728
with:
4829
github_token: ${{ secrets.GITHUB_TOKEN }}
49-
publish_dir: ./dist
30+
publish_dir: ./dist

0 commit comments

Comments
 (0)