Skip to content

Commit

Permalink
https://awesomefalcon1.github.io/
Browse files Browse the repository at this point in the history
  • Loading branch information
codejedi-ai committed Feb 9, 2025
1 parent 67c07dd commit 3c7bd94
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 25 deletions.
58 changes: 38 additions & 20 deletions .github/workflows/static.yml
Original file line number Diff line number Diff line change
@@ -1,43 +1,61 @@
# Simple workflow for deploying static content to GitHub Pages
name: Deploy static content to Pages
name: Node.js CI and Deploy

on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]

# Allows you to run this workflow manually from the Actions tab
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false

jobs:
# Single deploy job since we're just deploying
build-test:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x, 20.x, 22.x]

steps:
- uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Build
run: npm run build --if-present

- name: Test
run: npm test

- name: Upload artifact
if: matrix.node-version == '18.x'
uses: actions/upload-pages-artifact@v2
with:
path: './dist'

deploy:
needs: build-test
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload entire repository
path: '.'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
uses: actions/deploy-pages@v3
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.vs/
.vscode/
.DS_Store
node_modules/
node_modules/
dist/
3 changes: 0 additions & 3 deletions Notes

This file was deleted.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
"scripts": {
"dev": "vite",
"build": "vite build",
"preview": "vite preview"
"preview": "vite preview",
"test": "echo \"No tests specified\" && exit 0"
},
"devDependencies": {
"vite": "^6.1.0"
Expand Down
7 changes: 7 additions & 0 deletions vite.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
export default {
base: '/awesomefalcon1.github.io/',
build: {
outDir: 'dist',
sourcemap: true
}
}

0 comments on commit 3c7bd94

Please sign in to comment.