build(deps): Bump actions/setup-node from 4 to 6 #16
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, develop] | |
| pull_request: | |
| branches: [main, develop] | |
| jobs: | |
| commitlint: | |
| name: Lint Commit Messages | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'pull_request' | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - uses: wagoid/commitlint-github-action@v6 | |
| with: | |
| configFile: commitlint.config.js | |
| test: | |
| name: Test (Node ${{ matrix.node-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node-version: [18, 20, 22] | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Typecheck | |
| run: npx turbo run typecheck | |
| - name: Run tests | |
| run: npx turbo run test | |
| - name: Build packages | |
| run: npx turbo run build | |
| - name: Check package sizes | |
| run: | | |
| for pkg in geo-audit geo-seo geomark geokit; do | |
| echo "--- $pkg ---" | |
| cd packages/$pkg | |
| OUTPUT=$(npm pack --dry-run 2>&1) | |
| echo "$OUTPUT" | |
| SIZE=$(echo "$OUTPUT" | grep "package size" | awk '{print $NF}' | sed 's/kB//') | |
| if (( $(echo "$SIZE > 100" | bc -l) )); then | |
| echo "--- $pkg size ($SIZE kB) exceeds 100 kB limit" | |
| exit 1 | |
| fi | |
| echo "--- $pkg size ($SIZE kB) is within limits" | |
| cd ../.. | |
| done |