Skip to content

Commit

Permalink
Automated GitHub Pages Deployment (#15)
Browse files Browse the repository at this point in the history
Closes #12

## Added Deploy Workflow
Added a deploy.yml file to automate the deployment process using GitHub
Actions.

## Set Base in Vite Config
Set the base property in vite.config.ts to ensure the app works
correctly on GitHub Pages.
  • Loading branch information
notmanjit authored Dec 27, 2024
1 parent d121df1 commit d14e541
Show file tree
Hide file tree
Showing 2 changed files with 95 additions and 165 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Deploy to GitHub Pages

on:
push:
branches:
- main

jobs:
deploy:
runs-on: ubuntu-latest

steps:
# Checkout the repository
- name: Checkout repository
uses: actions/checkout@v3

# Set up Node.js environment
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '16'

# Install dependencies
- name: Install dependencies
run: npm install || yarn install

# Build the project
- name: Build the project
run: npm run build || yarn build

# Deploy to GitHub Pages
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./dist
Loading

0 comments on commit d14e541

Please sign in to comment.