⚡ Upload sourcemaps #1235
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: ⚡ Upload sourcemaps | |
| on: | |
| workflow_run: | |
| workflows: ['⚡ Integration checks'] | |
| types: | |
| - completed | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: false | |
| permissions: | |
| actions: write | |
| contents: read | |
| jobs: | |
| sourcemaps-upload: | |
| name: ⚙️ Build app | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Dump GitHub context | |
| env: | |
| GITHUB_CONTEXT: ${{ toJson(github) }} | |
| run: | | |
| echo "$GITHUB_CONTEXT" | |
| - name: ⬇️ Checkout repo | |
| uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
| with: | |
| ref: ${{ github.event.workflow_run.head_branch }} | |
| - name: 📦 Setup bun | |
| uses: oven-sh/setup-bun@735343b667d3e6f658f44d0eca948eb6282f2b76 # v2.0.2 | |
| with: | |
| bun-version: latest | |
| - name: ⎔ Setup node | |
| uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0 | |
| with: | |
| node-version-file: '.node-version' | |
| # cache: 'bun' | |
| cache-dependency-path: ./package.json | |
| - name: 📥 Install deps | |
| run: bun install --frozen-lockfile | |
| - name: ⚙️ Build | |
| run: bun build-sourcemaps | |
| - name: 📡 upload-sourcemap | |
| env: | |
| CURRENT_BRANCH: ${{ github.event.workflow_run.head_branch }} | |
| DEFAULT_BRANCH: ${{ github.event.repository.default_branch }} | |
| CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} | |
| R2_DOCUMENTS_ACCESS_KEY_ID: ${{ secrets.R2_DOCUMENTS_ACCESS_KEY_ID }} | |
| R2_DOCUMENTS_SECRET_ACCESS_KEY: ${{ secrets.R2_DOCUMENTS_SECRET_ACCESS_KEY }} | |
| run: bun run upload-sourcemaps | |