🔧 Migrate from npm to Bun (#2097)

This commit is contained in:
Alejandra
2026-01-20 22:35:30 +01:00
committed by GitHub
parent ab7c28c038
commit fb2a02345b
13 changed files with 989 additions and 6815 deletions

View File

@@ -20,9 +20,7 @@ jobs:
with:
ref: ${{ github.head_ref }}
token: ${{ secrets.FULL_STACK_FASTAPI_TEMPLATE_REPO_TOKEN }}
- uses: actions/setup-node@v6
with:
node-version: lts/*
- uses: oven-sh/setup-bun@v2
- uses: actions/setup-python@v6
with:
python-version: "3.10"
@@ -32,7 +30,7 @@ jobs:
version: "0.4.15"
enable-cache: true
- name: Install dependencies
run: npm ci
run: bun ci
- run: uv sync
working-directory: backend
- run: uv run bash scripts/generate-client.sh

View File

@@ -48,9 +48,7 @@ jobs:
fail-fast: false
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: lts/*
- uses: oven-sh/setup-bun@v2
- uses: actions/setup-python@v6
with:
python-version: '3.10'
@@ -66,7 +64,7 @@ jobs:
enable-cache: true
- run: uv sync
working-directory: backend
- run: npm ci
- run: bun ci
working-directory: frontend
- run: uv run bash scripts/generate-client.sh
env:
@@ -74,7 +72,7 @@ jobs:
- run: docker compose build
- run: docker compose down -v --remove-orphans
- name: Run Playwright tests
run: docker compose run --rm playwright npx playwright test --fail-on-flaky-tests --trace=retain-on-failure --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
run: docker compose run --rm playwright bunx playwright test --fail-on-flaky-tests --trace=retain-on-failure --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
- run: docker compose down -v --remove-orphans
- name: Upload blob report to GitHub Actions Artifacts
if: ${{ !cancelled() }}
@@ -94,11 +92,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: 20
- uses: oven-sh/setup-bun@v2
- name: Install dependencies
run: npm ci
run: bun ci
- name: Download blob reports from GitHub Actions Artifacts
uses: actions/download-artifact@v7
with:
@@ -106,7 +102,7 @@ jobs:
pattern: blob-report-*
merge-multiple: true
- name: Merge into HTML Report
run: npx playwright merge-reports --reporter html ./all-blob-reports
run: bunx playwright merge-reports --reporter html ./all-blob-reports
working-directory: frontend
- name: Upload HTML report
uses: actions/upload-artifact@v6

View File

@@ -37,9 +37,7 @@ jobs:
# To be able to commit it needs the head branch of the PR, the remote one
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0
- uses: actions/setup-node@v6
with:
node-version: lts/*
- uses: oven-sh/setup-bun@v2
- name: Set up Python
uses: actions/setup-python@v6
with:
@@ -54,7 +52,7 @@ jobs:
- name: Install backend dependencies
run: uv sync --all-packages
- name: Install frontend dependencies
run: npm ci
run: bun ci
- name: Run prek - pre-commit
id: precommit
run: uvx prek run --from-ref origin/${GITHUB_BASE_REF} --to-ref HEAD --show-diff-on-failure