Generate and PR #10
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
| # Update the generation and create a new PR | |
| name: Generate and PR | |
| on: | |
| # schedule manually | |
| workflow_dispatch: | |
| inputs: | |
| # On workflow dispatch, `branch` is selected by default | |
| # You can access it in `github.ref_name` | |
| backend_commit: | |
| description: "Commit hash for the server repo" | |
| required: true | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Update config.ini | |
| run: .generation/update_config.py --backendCommit ${{ github.event.inputs.backend_commit }} | |
| - name: Generate Code | |
| run: | | |
| .generation/generate.py python | |
| .generation/generate.py typescript | |
| - name: Create Pull Request | |
| uses: peter-evans/create-pull-request@v5 | |
| with: | |
| title: "Code for backend commit ${{ github.event.inputs.backend_commit }}" | |
| commit-message: "Code for backend commit ${{ github.event.inputs.backend_commit }}" |