Add support for importing translation files directly #67
Workflow file for this run
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: Pipeline | |
| on: | |
| push: | |
| branches: [main] | |
| paths: | |
| - 'package.json' | |
| - 'bun.lock' | |
| - 'turbo.json' | |
| - 'packages/**/src/**' | |
| - 'packages/**/package.json' | |
| - '.changeset/**' | |
| - '.github/workflows/pipeline.yml' | |
| pull_request: | |
| branches: [main] | |
| types: [opened, synchronize, reopened] | |
| paths: | |
| - 'package.json' | |
| - 'bun.lock' | |
| - 'turbo.json' | |
| - 'packages/**/src/**' | |
| - 'packages/**/package.json' | |
| - '.changeset/**' | |
| - '.github/workflows/pipeline.yml' | |
| workflow_dispatch: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| # Cancel in-progress runs on PRs (new push makes old run irrelevant) | |
| # but never cancel on main (could interrupt a release) | |
| cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
| jobs: | |
| build: | |
| name: Building | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: ./.github/actions/bun | |
| - name: Build all packages | |
| run: bun run build | |
| - name: Upload dist artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: dist | |
| path: packages/*/dist/ | |
| retention-days: 1 | |
| check: | |
| name: Type Checking | |
| needs: [build] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: ./.github/actions/bun | |
| - name: Download dist artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: dist | |
| path: packages | |
| - name: Run the type checker | |
| run: bun run check --filter "./packages/*" | |
| lint: | |
| name: Linting | |
| needs: [build] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: ./.github/actions/bun | |
| - name: Download dist artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: dist | |
| path: packages | |
| - name: Run the linter | |
| run: bun run lint | |
| test: | |
| name: Testing | |
| needs: [build] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: ./.github/actions/bun | |
| - name: Download dist artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: dist | |
| path: packages | |
| - name: Run tests | |
| run: bun run test | |
| - name: Upload coverage | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage | |
| path: packages/*/.coverage/ | |
| retention-days: 7 | |
| process: | |
| name: Processing Changesets | |
| needs: [check, lint, test] | |
| runs-on: ubuntu-latest | |
| outputs: | |
| published: ${{ steps.changesets.outputs.published }} | |
| if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} | |
| permissions: | |
| contents: write | |
| id-token: write | |
| pull-requests: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: ./.github/actions/bun | |
| - name: Process changesets | |
| id: changesets | |
| uses: changesets/action@v1 | |
| with: | |
| version: bun run release:version | |
| publish: bun run release:publish | |
| title: 'Pending Releases' | |
| commit: 'Update changelog and release' | |
| - run: | | |
| echo "published=${{ steps.changesets.outputs.published }}" >> $GITHUB_OUTPUT | |
| snapshot: | |
| name: Releasing Snapshot | |
| needs: [process] | |
| runs-on: ubuntu-latest | |
| if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' && needs.process.outputs.published == 'false' }} | |
| permissions: | |
| contents: read | |
| id-token: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: ./.github/actions/bun | |
| - name: Publish snapshot version | |
| run: | | |
| bun run release:snapshot:version | |
| bun run release:snapshot:publish |