Create RC PR #37
Workflow file for this run
This file contains 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: Create RC PR | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 14 * * 1,3,5' # Run on Monday, Wednesday, and Friday at 14:00 UTC | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
jobs: | |
create_rc_pr: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
with: | |
fetch-depth: 0 | |
sparse-checkout: 'tasks' | |
- name: Install python | |
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0 | |
with: | |
python-version: 3.11 | |
cache: "pip" | |
- name: Install Python dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
pip install -r tasks/libs/requirements-github.txt | |
- name: Determine the release active branch | |
run: | | |
echo "RELEASE_BRANCH=$(inv -e release.get-active-release-branch)" >> $GITHUB_ENV | |
- name: Check for changes since last RC | |
id: check_for_changes | |
run: | | |
echo COUNT=$(inv -e release.check-for-changes -r ${{ env.RELEASE_BRANCH }}) >> $GITHUB_ENV | |
- name: Checkout release branch | |
if: ${{ steps.check_for_changes.outputs.COUNT != '0'}} | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
with: | |
ref: ${{ env.RELEASE_BRANCH }} | |
fetch-depth: 0 | |
sparse-checkout: 'tasks' | |
- name: Create RC PR | |
if: ${{ steps.check_for_changes.outputs.COUNT != '0'}} | |
run: | | |
git config user.name "github-actions[bot]" | |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
git fetch | |
inv -e release.create-rc --slack-webhook=${{ secrets.AGENT_RELEASE_SYNC_SLACK_WEBHOOK }} |