improved Benchmark #182
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [ main, master ] | |
| pull_request: | |
| jobs: | |
| backend: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: backend | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-java@v4 | |
| with: | |
| distribution: temurin | |
| java-version: '21' | |
| cache: maven | |
| - name: Run Spotless check | |
| run: mvn -B spotless:check || { echo "Spotless check failed. Run 'mvn spotless:apply' inside backend directory locally, commit, and push."; exit 1; } | |
| - name: Run Checkstyle (fail on violations) | |
| run: mvn -B checkstyle:check | |
| - name: Generate Checkstyle report | |
| run: mvn -B checkstyle:checkstyle | |
| - name: Upload Checkstyle report | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: checkstyle-report | |
| path: backend/target/checkstyle/* | |
| retention-days: 15 | |
| - name: Build backend | |
| run: mvn -B test | |
| frontend: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: frontend | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| cache: npm | |
| cache-dependency-path: frontend/package-lock.json | |
| - name: Install dependencies | |
| run: npm install | |
| - name: Build frontend | |
| run: npm run build |