Sync #650
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: "Sync" | |
on: | |
workflow_dispatch: | |
schedule: | |
# Every day at 3:15 AM UTC | |
- cron: '15 3 * * *' | |
jobs: | |
sync: | |
name: "Get new GitHub release data" | |
if: ${{ github.repository == 'gap-system/GapWWW' }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: "Check out the GapWWW repository in order to make changes to it" | |
uses: actions/checkout@v3 | |
- name: "Clone GAP for its most up-to-date release scripts" | |
uses: actions/checkout@v3 | |
with: | |
repository: gap-system/gap | |
ref: master | |
path: tmp/gap/ | |
fetch-depth: 1 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: 3.9 | |
- name: "Install the required Python modules" | |
run: pip3 install PyGithub requests python-dateutil | |
- name: "Run the GAP dev release script for updating the website" | |
run: python -u ./tmp/gap/dev/releases/update_website.py | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: "Remove GAP clone" | |
run: rm -rf ./tmp/gap | |
- name: "Make a pull request to the master branch of this repository" | |
uses: peter-evans/create-pull-request@v4 | |
with: | |
base: master | |
branch: auto/sync-with-github-releases | |
commit-message: Sync data from GAP's GitHub release system | |
title: Sync data from GAP's GitHub release system | |
body: >- | |
Automatically created by a GitHub Actions workflow, using with the | |
GAP release script `dev/release/update_website.py`. | |
You may wish to squash and merge this pull request, in order | |
to give it a more descriptive commit message. |