Catalog sync #26
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: Catalog sync | |
| on: | |
| schedule: | |
| - cron: "0 */6 * * *" | |
| workflow_dispatch: | |
| inputs: | |
| force: | |
| description: Re-extract even if command-code version is unchanged | |
| type: boolean | |
| default: false | |
| permissions: | |
| contents: write | |
| issues: write | |
| pull-requests: write | |
| jobs: | |
| sync: | |
| name: catalog-pr | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| token: ${{ secrets.RELEASE_SYNC_TOKEN || secrets.CATALOG_PUSH_TOKEN || secrets.GITHUB_TOKEN }} | |
| - uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: "1.3.14" | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Ensure automation labels | |
| env: | |
| GH_TOKEN: ${{ secrets.RELEASE_SYNC_TOKEN || secrets.CATALOG_PUSH_TOKEN || secrets.GITHUB_TOKEN }} | |
| run: | | |
| gh label create catalog-break --force --color B60205 \ | |
| --description "Catalog model extraction failed in CI" || true | |
| gh label create automation --force --color 0E8A16 \ | |
| --description "Automated bot activity" || true | |
| - name: Open catalog PR | |
| env: | |
| CI: "true" | |
| FORCE: ${{ inputs.force }} | |
| GH_TOKEN: ${{ secrets.RELEASE_SYNC_TOKEN || secrets.CATALOG_PUSH_TOKEN || secrets.GITHUB_TOKEN }} | |
| GITHUB_TOKEN: ${{ secrets.RELEASE_SYNC_TOKEN || secrets.CATALOG_PUSH_TOKEN || secrets.GITHUB_TOKEN }} | |
| run: bun run scripts/catalog-sync-ci.ts |