ci: simplify .npmrc creation by removing unnecessary env variable dec… #5
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: | |
| - '**' | |
| pull_request: | |
| jobs: | |
| quick-check: | |
| if: github.ref != 'refs/heads/main' || github.event_name == 'pull_request' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: "Create .npmrc" | |
| run: echo "//private-registry.torln.com/:_authToken=\"${{ secrets.NPM_CONFIG_TOKEN }}\"" > .npmrc | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Type check | |
| run: bun run check | |
| - name: Lint | |
| run: bun run lint | |
| main-check: | |
| if: github.ref == 'refs/heads/main' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: "Create .npmrc" | |
| run: echo "//private-registry.torln.com/:_authToken=\"${{ secrets.NPM_CONFIG_TOKEN }}\"" > .npmrc | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Type check | |
| run: bun run check | |
| - name: Lint | |
| run: bun run lint | |
| - name: Build library | |
| run: bun run build | |
| - name: Build storybook | |
| run: bun run storybook:build |