Skip to content

Commit 07b7734

Browse files
Merge pull request #26 from ossdaiict/aditya/feature
Aditya/feature
2 parents 4336346 + 0d9c028 commit 07b7734

File tree

2 files changed

+40
-35
lines changed

2 files changed

+40
-35
lines changed

.github/workflows/deploy.yml

Lines changed: 39 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Deploy to GitHub Pages
22

33
on:
44
push:
5-
branches: [ main, master ]
5+
branches: [ main, master, aditya/feature ]
66
workflow_dispatch:
77

88
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
@@ -18,41 +18,46 @@ concurrency:
1818
cancel-in-progress: false
1919

2020
jobs:
21-
build-and-deploy:
21+
# Build job
22+
build:
2223
runs-on: ubuntu-latest
24+
steps:
25+
- name: Checkout
26+
uses: actions/checkout@v4
27+
28+
- name: Setup Node.js
29+
uses: actions/setup-node@v4
30+
with:
31+
node-version: '18'
32+
cache: 'npm'
33+
cache-dependency-path: './Slot-Booking-System-Frontend/package-lock.json'
34+
35+
- name: Install dependencies
36+
run: |
37+
cd Slot-Booking-System-Frontend
38+
npm ci
39+
40+
- name: Build
41+
run: |
42+
cd Slot-Booking-System-Frontend
43+
npm run build
44+
45+
- name: Setup Pages
46+
uses: actions/configure-pages@v4
47+
48+
- name: Upload artifact
49+
uses: actions/upload-pages-artifact@v3
50+
with:
51+
path: './Slot-Booking-System-Frontend/dist'
52+
53+
# Deploy job
54+
deploy:
2355
environment:
2456
name: github-pages
2557
url: ${{ steps.deployment.outputs.page_url }}
26-
58+
runs-on: ubuntu-latest
59+
needs: build
2760
steps:
28-
- name: Checkout
29-
uses: actions/checkout@v4
30-
31-
- name: Setup Node.js
32-
uses: actions/setup-node@v4
33-
with:
34-
node-version: '18'
35-
cache: 'npm'
36-
cache-dependency-path: './Slot-Booking-System-Frontend/package-lock.json'
37-
38-
- name: Install dependencies
39-
run: |
40-
cd Slot-Booking-System-Frontend
41-
npm ci
42-
43-
- name: Build
44-
run: |
45-
cd Slot-Booking-System-Frontend
46-
npm run build
47-
48-
- name: Setup Pages
49-
uses: actions/configure-pages@v4
50-
51-
- name: Upload artifact
52-
uses: actions/upload-pages-artifact@v3
53-
with:
54-
path: './Slot-Booking-System-Frontend/dist'
55-
56-
- name: Deploy to GitHub Pages
57-
id: deployment
58-
uses: actions/deploy-pages@v4
61+
- name: Deploy to GitHub Pages
62+
id: deployment
63+
uses: actions/deploy-pages@v4

Slot-Booking-System-Frontend/vite.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ import tailwindcss from '@tailwindcss/vite'
44
// https://vite.dev/config/
55
export default defineConfig({
66
plugins: [react(), tailwindcss()],
7-
base: '/SLoP5.0-Slot-Booking-System/',
7+
base: '/SLoP5.0-Slot-Booking-System/', // Commented out for local development
88
})

0 commit comments

Comments
 (0)