Skip to content

Generate new lists #1092

Generate new lists

Generate new lists #1092

Workflow file for this run

name: Generate new lists
on:
push:
branches:
- main
schedule:
- cron: '0 0 * * *'
jobs:
generate:
runs-on: ubuntu-latest
steps:
- name: Checkout master branch
uses: actions/checkout@v2
with:
ref: main
path: main
- name: Checkout lists branch
uses: actions/checkout@v2
with:
ref: lists
path: lists
- name: Generate lists
run: |
cd ${GITHUB_WORKSPACE}/main/
chmod +x ./generate-lists.sh
./generate-lists.sh
- name: Generate lists.json
run: |
cd ${GITHUB_WORKSPACE}/main/
chmod +x ./generate-json.sh
./generate-json.sh
- name: Generate README.md
run: |
cd ${GITHUB_WORKSPACE}/main/
chmod +x ./generate-readme.sh
./generate-readme.sh
- name: Push changes to GitHub
run: |
cd ${GITHUB_WORKSPACE}/lists/
rsync -vrth --delete --exclude ".git*" ${GITHUB_WORKSPACE}/main/output/ ${GITHUB_WORKSPACE}/lists/
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
git add -A
git commit -am "Generated by GitHub Actions (${GITHUB_SHA::7})"
git push -qf origin lists