Skip to content

Commit aa6c1ec

Browse files
committed
deploy.yml を追加する
1 parent ce21a8f commit aa6c1ec

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

.github/workflows/deploy.yml

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Deploy
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
build:
10+
name: Build
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout repo
15+
uses: actions/checkout@v3
16+
17+
- name: Setup Node
18+
uses: actions/setup-node@v3
19+
with:
20+
node-version: 16
21+
22+
- name: Install dependencies
23+
run: npm ci
24+
25+
- name: Build project
26+
run: npm run build
27+
28+
- name: Upload artifact
29+
uses: actions/upload-pages-artifact@v1
30+
with:
31+
path: ./dist
32+
33+
deploy:
34+
needs: build
35+
permissions:
36+
pages: write
37+
id-token: write
38+
environment:
39+
name: github-pages
40+
url: ${{ steps.deployment.outputs.page_url }}
41+
runs-on: ubuntu-latest
42+
steps:
43+
- name: Deploy to GitHub Pages
44+
id: deployment
45+
uses: actions/deploy-pages@v1

0 commit comments

Comments
 (0)