Schedule RC #755
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: Schedule RC | |
| on: | |
| schedule: | |
| - cron: "14 3 * * *" # 3:14 UTC - slightly offset to avoid high-load times of other scheduled workflows | |
| workflow_dispatch: | |
| jobs: | |
| cut-release-candidate: | |
| name: Cut RC | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| environment: PUSH_TO_RC_BRANCH | |
| steps: | |
| - name: Create GitHub App Token | |
| uses: actions/create-github-app-token@f8d387b68d61c58ab83c6c016672934102569859 # v3.0.0 | |
| id: app-token | |
| with: | |
| app-id: ${{ vars.PUSH_TO_RC_BRANCH_APP_ID }} | |
| private-key: ${{ secrets.PUSH_TO_RC_BRANCH_PRIVATE_KEY }} | |
| - name: Checkout | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| repository: ${{ github.repository }} | |
| ref: ${{ github.ref }} | |
| token: ${{ steps.app-token.outputs.token }} | |
| - name: Cut Release Candidate | |
| shell: bash | |
| run: | | |
| git config --global user.email "infra+github-automation@dfinity.org" | |
| git config --global user.name "IDX GitHub Automation" | |
| RC_BRANCH_NAME="rc--$(date '+%Y-%m-%d_%H-%M')" | |
| git switch --force-create "$RC_BRANCH_NAME" HEAD | |
| git push --force --set-upstream origin "$RC_BRANCH_NAME" |