update-hours-and-concat-spacefinder-data #940
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-hours-and-concat-spacefinder-data | |
on: | |
push: | |
branches: | |
- gh-pages-ucam | |
schedule: | |
- cron: 34 2 * * * | |
jobs: | |
update-and-concat-data: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
path: main | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '16' | |
- name: Update hours, concat space files and commit | |
run: | | |
cd main | |
npm install | |
npm run toggleOpeningHours | |
npm run concat | |
git config --global user.name 'Spacefinder Bot' | |
git config --global user.email '<>' | |
git add --all | |
git diff-index --quiet HEAD || (git commit -am "Workflow: Update hours and generate master space data file" && git push) |