Skip to content

Commit

Permalink
fix base path
Browse files Browse the repository at this point in the history
  • Loading branch information
bartektelec committed Feb 11, 2024
1 parent 8a362a8 commit 1a67966
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 38 deletions.
69 changes: 35 additions & 34 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
@@ -1,50 +1,51 @@
name: NodeJS with Webpack
# Simple workflow for deploying static content to GitHub Pages
name: Deploy static content to Pages

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

jobs:
build:
runs-on: ubuntu-latest
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

strategy:
matrix:
node-version: [20.x]
# Sets the GITHUB_TOKEN permissions to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

steps:
- uses: actions/checkout@v3
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true

- name: Use Node.js ${{ matrix.node-version }}
jobs:
# Single deploy job since we're just deploying
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@v3
with:
node-version: ${{ matrix.node-version }}

node-version: 18
cache: "npm"
- name: Install dependencies
run: npm install
- name: Build
run: |
npm install
npm run build
- name: Configure GitHub Pages
run: npm run build
- name: Setup Pages
uses: actions/configure-pages@v3

- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v1
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
# upload entire directory
path: "dist"
deploy:
permissions:
contents: read
pages: write
id-token: write
runs-on: ubuntu-latest
needs: build
environment:
name: github-pages
url: ${{steps.deployment.outputs.page_url}}
steps:
# Upload dist repository
path: "./dist"
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
9 changes: 5 additions & 4 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { defineConfig } from 'vitest/config'
import { defineConfig } from "vitest/config";

export default defineConfig({
base: "/pebble/",
test: {
globals: true
}
})
globals: true,
},
});

0 comments on commit 1a67966

Please sign in to comment.