Skip to content

Commit 26d5ed2

Browse files
authored
Update build-test-deploy.yml
1 parent 5e795b3 commit 26d5ed2

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

.github/workflows/build-test-deploy.yml

+38
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,41 @@ jobs:
2828
node-version: '20.x'
2929
- run: npm install
3030
- run: npm test
31+
32+
deploy:
33+
needs: test
34+
35+
permissions:
36+
contents: write
37+
pages: write
38+
id-token: write
39+
40+
environment:
41+
name: production
42+
url: ${{ steps.deployment.outputs.page_url }}
43+
44+
runs-on: ubuntu-latest
45+
46+
steps:
47+
- name: checkout rep
48+
uses: actions/checkout@v4
49+
with:
50+
token: ${{ secret.GITHUB_TOKEN }}
51+
- name: use node.js
52+
uses: actions/setup-node@v4
53+
with:
54+
node-version: '20.x'
55+
- name: configure github pages
56+
uses: actions/configure-pages@v4
57+
with:
58+
static_site_generator: text
59+
- run: npm isntall
60+
- run: npm run build
61+
- name: upload artifacts
62+
uses: actions/upload-pages-artifact@v3
63+
with:
64+
path: './out'
65+
- name: deploy
66+
id: deployment
67+
uses: actions/deploy-pages@v4
68+

0 commit comments

Comments
 (0)