Skip to content

Commit

Permalink
Try to make frontend the base project
Browse files Browse the repository at this point in the history
  • Loading branch information
AnnsAnns committed May 6, 2024
1 parent da40657 commit 9bc3fab
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/build_frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,9 @@ concurrency:
jobs:
# Single deploy job since we're just deploying
deploy:
defaults:
run:
working-directory: ./frontend
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}frontend/
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -38,12 +35,21 @@ jobs:
- name: Install Bun
uses: oven-sh/setup-bun@v1

- name: Install
- name: CD frontend
run: cd frontend

- name: Install Docs
run: bun install

- name: Build
run: bun run build

- name: Create base dist folder
run: mkdir -p ../dist

- name: Copy frontend dist to base dist
run: cp -r .frontend/dist ./dist

- name: Setup Pages
uses: actions/configure-pages@v5

Expand Down
2 changes: 1 addition & 1 deletion frontend/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ import react from '@vitejs/plugin-react-swc'
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
base: "/teamagochi/frontend/"
base: "/teamagochi/"
})

0 comments on commit 9bc3fab

Please sign in to comment.