Update Games List #1141
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: Update Games List | |
on: | |
schedule: | |
- cron: "0 2 * * *" | |
push: | |
branches: ["auto_update_games"] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js 14 | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 14.x | |
cache: yarn | |
- name: Yarn Install | |
run: yarn install | |
- run: ./generate-games.sh | |
- name: Create Pull Request | |
id: cpr | |
uses: peter-evans/create-pull-request@v3 | |
with: | |
token: ${{ secrets.PAT }} | |
commit-message: Auto-update games | |
branch: auto-games-update | |
title: "[Bot] Update Games List" | |
- name: Enable Pull Request Automerge | |
if: steps.cpr.outputs.pull-request-operation == 'created' | |
uses: peter-evans/enable-pull-request-automerge@v1 | |
with: | |
token: ${{ secrets.PAT }} | |
pull-request-number: ${{ steps.cpr.outputs.pull-request-number }} |