release: Feature Freeze for Audit #71
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: Validate PR | |
| on: | |
| pull_request: | |
| branches: [main] | |
| paths: | |
| - 'sdks/**' | |
| jobs: | |
| validate-changeset: | |
| name: Validate Changeset | |
| runs-on: ubuntu-latest | |
| if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-changeset') }} | |
| defaults: | |
| run: | |
| working-directory: sdks | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - name: Setup git for changeset | |
| run: | | |
| git fetch origin main:main | |
| git branch --set-upstream-to=origin/main main || true | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 'lts/*' | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 10.12.3 | |
| - name: Get pnpm store directory | |
| shell: bash | |
| run: echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV | |
| - name: Setup pnpm cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ env.STORE_PATH }} | |
| key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-pnpm-store- | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Check for changeset | |
| run: | | |
| if ! find .changeset -name "*.md" -not -name "README.md" -print -quit | grep -q .; then | |
| echo "❌ No changeset found!" | |
| echo "Please run 'pnpm changeset' to create a changeset for your changes." | |
| echo "If this PR doesn't need a changeset, add the 'no-changeset' label." | |
| exit 1 | |
| else | |
| echo "✅ Changeset found!" | |
| fi | |
| - name: Validate changeset format | |
| run: pnpm changeset status |