Create PR for adding new runners #60
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: runner-update | |
run-name: Create PR for adding new runners | |
on: | |
schedule: | |
- cron: '0 8 * * SAT' | |
workflow_dispatch: | |
defaults: | |
run: | |
working-directory: ./updater | |
jobs: | |
add-runners: | |
name: Add runners | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: Install packages | |
run: npm install | |
- name: Add runners to list | |
env: | |
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }} | |
run: npm start | |
- name: Get current date | |
run: echo "date=$(date +'%Y-%m-%d')" >> $GITHUB_ENV | |
- name: Create PR | |
uses: peter-evans/create-pull-request@v6 | |
with: | |
title: Add new runners as of ${{ env.date }} | |
body: Automatic PR to update the list with new runners as of last week | |
commit-message: Add new runners | |
branch: strawberry-bot/add-runners | |
delete-branch: true |