feat: add Astro docs site, CLI tooling, and versioning workflow #9
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: Changeset Check | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| changeset-check: | |
| name: Check for Changeset | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 9.0.0 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - name: Install Dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Check for Changesets | |
| id: check | |
| run: | | |
| # Skip check for version bump PRs | |
| if [[ "${{ github.head_ref }}" == *"version-packages"* ]]; then | |
| echo "Skipping changeset check for version PR" | |
| exit 0 | |
| fi | |
| # Skip check for chore commits that don't need changesets | |
| if [[ "${{ github.head_ref }}" == chore/* ]] || \ | |
| [[ "${{ github.head_ref }}" == docs/* ]] || \ | |
| [[ "${{ github.head_ref }}" == ci/* ]]; then | |
| echo "Skipping changeset check for chore/docs/ci PR" | |
| exit 0 | |
| fi | |
| # Check if changesets exist | |
| pnpm changeset status --since=origin/${{ github.base_ref }} | |
| - name: Verify Versioning Setup | |
| run: pnpm verify:versioning | |
| - name: Comment on PR | |
| if: failure() | |
| uses: actions/github-script@v7 | |
| with: | |
| script: | | |
| github.rest.issues.createComment({ | |
| issue_number: context.issue.number, | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| body: '⚠️ **Versioning verification failed**\n\nPlease run `pnpm verify:versioning` locally to check the issues.\n\nCommon issues:\n- Missing changesets: Run `pnpm changeset`\n- Changelog sync issues: Run `pnpm changelog:sync`\n- Sidebar configuration: Check `apps/docs/astro.config.mjs`\n\nSee [Pre-Merge Checklist](.github/PRE_MERGE_CHECKLIST.md) for details.' | |
| }) |