name: Sync OpenCode Skills on: push: branches: - main paths: - 'plugins/svelte/skills/**' permissions: contents: write pull-requests: write jobs: sync-skills: # prevents this action from running on forks if: github.repository == 'sveltejs/mcp' name: Sync Skills to OpenCode Package and Update Docs runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v6 with: fetch-depth: 0 - name: Setup Node.js uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0 with: node-version: 24 package-manager-cache: false # pnpm is not installed yet - name: Install pnpm shell: bash run: | PNPM_VER=$(jq -r '.packageManager | if .[0:5] == "pnpm@" then .[5:] else "packageManager in package.json does not start with pnpm@\n" | halt_error(1) end' package.json) echo installing pnpm version $PNPM_VER npm i -g pnpm@$PNPM_VER - name: Setup Node.js with pnpm cache uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0 with: node-version: 24 package-manager-cache: true # caches pnpm via packageManager field in package.json cache: 'pnpm' - name: Install dependencies run: pnpm install --frozen-lockfile --prefer-offline --ignore-scripts - name: Sync skills folder run: pnpm sync-opencode-skills - name: Generate skills documentation run: pnpm generate-skill-docs - name: Check for changes id: git-check run: | git diff --exit-code packages/opencode/skills documentation/docs/60-skills/10-skills.md || echo "changed=true" >> $GITHUB_OUTPUT - name: Create Pull Request if: steps.git-check.outputs.changed == 'true' uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 # v8.1.0 with: token: ${{ secrets.GITHUB_TOKEN }} commit-message: 'chore: sync skills and update documentation' branch: chore/sync-opencode-skills delete-branch: true title: 'chore: sync skills and update documentation' body: | ## Summary Automatically synced skills and updated documentation. This PR was triggered by changes to the skills folder in `plugins/svelte/skills/`. ## Changes - Synced `packages/opencode/skills/` with latest skill definitions - Updated `documentation/docs/60-skills/10-skills.md` with latest skill documentation ## Generated by GitHub Action: Sync OpenCode Skills labels: | chore documentation automated