Skip to content

Commit 30bc274

Browse files
committed
refactor: consolidate CI workflows and enhance deployment process
1 parent 672d16a commit 30bc274

File tree

2 files changed

+35
-50
lines changed

2 files changed

+35
-50
lines changed

.github/workflows/ci.yaml

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,29 @@
1-
name: Build
1+
name: Build and Deploy
22

33
on:
4+
push:
5+
branches:
6+
- dev
47
pull_request:
58
branches:
69
- dev
710
types:
811
- closed
9-
push:
10-
branches:
11-
- dev
1212

1313
workflow_dispatch:
1414

15+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
16+
permissions:
17+
contents: read
18+
pages: write
19+
id-token: write
20+
21+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
22+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
23+
concurrency:
24+
group: "pages"
25+
cancel-in-progress: false
26+
1527
jobs:
1628
build:
1729
name: Build
@@ -34,8 +46,24 @@ jobs:
3446
VITE_EMAIL_API_KEY: ${{ secrets.VITE_EMAIL_API_KEY }}
3547
run: npm run build
3648

37-
- name: Upload artifact to enable deployment
38-
uses: actions/upload-artifact@v4
49+
- name: Setup Pages
50+
uses: actions/configure-pages@v5
51+
52+
- name: Upload to GitHub Pages
53+
uses: actions/upload-pages-artifact@v3
3954
with:
40-
name: production-files
4155
path: ./dist
56+
57+
deploy:
58+
name: Deploy to GitHub Pages
59+
needs: build
60+
runs-on: ubuntu-latest
61+
62+
environment:
63+
name: github-pages
64+
url: ${{ steps.deployment.outputs.page_url }}
65+
66+
steps:
67+
- name: Deploy to GitHub Pages
68+
id: deployment
69+
uses: actions/deploy-pages@v4

.github/workflows/static.yml

Lines changed: 0 additions & 43 deletions
This file was deleted.

0 commit comments

Comments
 (0)