We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9d3acae commit f0bb37aCopy full SHA for f0bb37a
1 file changed
.github/workflows/deloy.yml
@@ -0,0 +1,32 @@
1
+name: GitHub Pages Deployment
2
+
3
+on:
4
+ push:
5
+ branches:
6
+ - main # main 브랜치에 push할 때 자동 배포
7
8
+jobs:
9
+ build:
10
+ name: Build and Deploy to GitHub Pages
11
+ runs-on: ubuntu-latest
12
13
+ steps:
14
+ - name: Checkout code
15
+ uses: actions/checkout@v3
16
17
+ - name: Setup Node.js
18
+ uses: actions/setup-node@v3
19
+ with:
20
+ node-version: 18 # 프로젝트에 맞는 Node.js 버전
21
22
+ - name: Install Dependencies
23
+ run: npm install
24
25
+ - name: Build Project
26
+ run: npm run build # 프로젝트에 맞는 빌드 명령어로 수정
27
28
+ - name: Deploy to GitHub Pages
29
+ uses: peaceiris/actions-gh-pages@v3
30
31
+ github_token: ${{ secrets.GITHUB_TOKEN }}
32
+ publish_dir: ./build # 빌드 결과물이 저장되는 디렉토리 (React는 보통 build)
0 commit comments