Skip to content

Commit

Permalink
feat: config gh pages
Browse files Browse the repository at this point in the history
  • Loading branch information
StanleyMasinde committed Jan 2, 2025
1 parent e9e0773 commit 7c6a0d6
Show file tree
Hide file tree
Showing 7 changed files with 47 additions and 31 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Deploy to pages

on:
push:
branches: ['main']

workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: 'pages'
cancel-in-progress: true

jobs:
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: './dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@ dist-ssr
*.njsproj
*.sln
*.sw?
dist/
Empty file removed docs/.gitkeep
Empty file.
1 change: 0 additions & 1 deletion docs/assets/index.8092b6d2.css

This file was deleted.

11 changes: 0 additions & 11 deletions docs/assets/index.bbbb913f.js

This file was deleted.

15 changes: 0 additions & 15 deletions docs/index.html

This file was deleted.

6 changes: 2 additions & 4 deletions vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ import vue from '@vitejs/plugin-vue'

// https://vitejs.dev/config/
export default defineConfig({
build: {
outDir: './docs',
},
plugins: [vue()]
plugins: [vue()],
base: 'pwa-generator'
})

0 comments on commit 7c6a0d6

Please sign in to comment.