Skip to content

Update NoIntro Database #19

Update NoIntro Database

Update NoIntro Database #19

name: Update NoIntro Database
on:
workflow_dispatch: {}
schedule:
- cron: "44 4 1 */3 *"
jobs:
update-nointro-database:
name: Update NoIntro Database
runs-on: ubuntu-24.04
env:
COMMIT_MESSAGE: "chore(database): Update NoIntro database"
AUTHOR: "gones-bot <159408161+gones-bot[bot]@users.noreply.github.com>"
steps:
- name: Generate Token
id: app-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ secrets.BOT_APP_ID }}
private-key: ${{ secrets.BOT_APP_PRIVATE_KEY }}
- name: Checkout code
uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
submodules: true
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
cache: true
- name: Download database
run: go run ./internal/database/generate/download
- name: Update CSV
run: go run -tags embed_nes_xml ./internal/database/generate/to_csv
- name: Create Pull Request
id: pr
uses: peter-evans/create-pull-request@v7
with:
token: ${{ steps.app-token.outputs.token }}
committer: ${{ env.AUTHOR }}
author: ${{ env.AUTHOR }}
add-paths: "*.csv"
commit-message: ${{ env.COMMIT_MESSAGE }}
branch: update-nointro-database
title: ${{ env.COMMIT_MESSAGE }}
body: |
This PR updates the NoIntro database.
Generated by the Update NoIntro Database Action.
View update log [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}).
labels: dependencies,nointro
- uses: peter-evans/enable-pull-request-automerge@v3
if: steps.pr.outputs.pull-request-operation == 'created'
with:
token: ${{ steps.app-token.outputs.token }}
pull-request-number: ${{ steps.pr.outputs.pull-request-number }}
merge-method: squash