Skip to content

Building and deploying GitHub pages #2143

Building and deploying GitHub pages

Building and deploying GitHub pages #2143

Workflow file for this run

name: Building and deploying GitHub pages
on:
# schedule runs _only_ for the default branch (for a repository) and the base branch (for a PR).
# See https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#onschedule for more info.
schedule:
# See https://help.github.com/en/actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows#scheduled-events-schedule
# run every day at 05:20 UTC
- cron: "20 5 * * *"
# also update pages on pushes to master
push:
branches:
- master
jobs:
daily_build:
runs-on: ubuntu-latest
env:
COMMIT_AUTHOR: Daily Deploy Action
COMMIT_AUTHOR_EMAIL: [email protected]
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install OPTIMADE
run: |
python -m pip install --upgrade pip
pip install -r make_ghpages/requirements.txt
- name: Make pages
run: cd make_ghpages && python make_pages.py
timeout-minutes: 120
- name: Commit to gh-pages
run: ./make_ghpages/commit.sh
- name: Push changes
uses: ad-m/[email protected]
with:
branch: gh-pages
force: true
github_token: ${{ secrets.GITHUB_TOKEN }}