Regenerate API client #1
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: Regenerate API client | |
| on: | |
| schedule: | |
| - cron: "0 3 * * 5" | |
| workflow_dispatch: | |
| jobs: | |
| gen-api: | |
| name: Regenerate API client | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| token: ${{ secrets.CI_PAT }} | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 | |
| with: | |
| bun-version-file: ".bun-version" | |
| - name: Install dependencies | |
| run: bun ci | |
| - name: Generate files | |
| run: bun run gen | |
| - name: Create or update Pull Request | |
| uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1 | |
| with: | |
| token: ${{ secrets.CI_PAT }} | |
| commit-message: "feat: regenerate api client" | |
| title: "feat: regenerate api client" | |
| committer: CI <ci@rman.dev> | |
| author: CI <ci@rman.dev> | |
| branch: gen-api | |
| delete-branch: true | |
| assignees: gameroman | |
| reviewers: gameroman | |
| labels: ci | |
| - name: Notify Discord | |
| if: always() | |
| uses: sarisia/actions-status-discord@eb045afee445dc055c18d3d90bd0f244fd062708 # v1.16.0 | |
| with: | |
| webhook: ${{ secrets.DISCORD_WEBHOOK }} | |
| status: ${{ job.status }} | |
| title: "Regenerate API client (#${{ github.run_number }})" | |
| description: | | |
| Status: **${{ job.status }}** | |
| Branch: ${{ github.ref_name }} | |
| Trigger: ${{ github.event_name }} | |
| Commit: ${{ github.sha }} |