Update .gitignore to exclude Cursor IDE, Vercel metadata, and duplica… #3
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/CD Pipeline | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| services: | |
| mongodb: | |
| image: mongo:6.0 | |
| ports: | |
| - 27017:27017 | |
| options: >- | |
| --health-cmd "mongosh --eval 'db.adminCommand(\"ping\")'" | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '18' | |
| cache: 'pnpm' | |
| - name: Install pnpm | |
| uses: pnpm/action-setup@v2 | |
| with: | |
| version: 8 | |
| - name: Install dependencies | |
| run: pnpm install | |
| - name: Lint code | |
| run: pnpm lint | |
| - name: Type check | |
| run: pnpm type-check | |
| - name: Test backend | |
| run: pnpm test:api | |
| env: | |
| MONGODB_URI: mongodb://localhost:27017/bitgame-test | |
| - name: Test frontend | |
| run: pnpm test:web | |
| - name: Test contracts | |
| run: pnpm test:contracts | |
| - name: Build applications | |
| run: pnpm build | |
| - name: Upload coverage reports | |
| uses: codecov/codecov-action@v3 | |
| if: success() | |
| deploy: | |
| needs: test | |
| runs-on: ubuntu-latest | |
| if: github.ref == 'refs/heads/main' | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Deploy to production | |
| run: echo "Deploy to production server" | |
| # Add your deployment commands here | |