refactor: remove SonarCloud setup documentation and disable integrati… #7
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: Code Quality | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main, develop ] | |
| jobs: | |
| code-quality: | |
| name: Code Quality Analysis | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # Needed for SonarCloud | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '18' | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Run ESLint with reporting | |
| run: | | |
| npx eslint . --format json --output-file eslint-report.json || true | |
| npx eslint . --format stylish | |
| - name: Check bundle size | |
| run: | | |
| npm run build | |
| du -sh dist/ | |
| find dist/ -name "*.js" -exec ls -lh {} \; | head -10 | |
| - name: Check for unused dependencies | |
| run: | | |
| npx depcheck --json > depcheck-report.json || true | |
| cat depcheck-report.json | |
| - name: Generate dependency tree | |
| run: npm ls --all > dependency-tree.txt || true | |
| - name: Upload reports | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: code-quality-reports | |
| path: | | |
| eslint-report.json | |
| depcheck-report.json | |
| dependency-tree.txt | |
| retention-days: 7 |