Skip to content

Merge branch 'main' of github.com:Sydney-Informatics-Hub/tidbits #29

Merge branch 'main' of github.com:Sydney-Informatics-Hub/tidbits

Merge branch 'main' of github.com:Sydney-Informatics-Hub/tidbits #29

Workflow file for this run

name: Deploy to github-pages
on:
push:
branches:
- main
permissions:
contents: write
jobs:
build-and-deploy:
concurrency: ci-${{ github.ref }} # Recommended if you intend to make multiple deployments in quick succession.
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.11"]
poetry-version: ["1.6.1"]
steps:
- name: Checkout 🛎️
uses: actions/checkout@v3
- name: Setup Python 🐍
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Setup poetry 🖋️
uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ matrix.poetry-version }}
- name: Setup a local virtual environment (if no poetry.toml file)
run: |
poetry config virtualenvs.create true --local
poetry config virtualenvs.in-project true --local
- uses: actions/cache@v3
name: Cache poetry dependencies
with:
path: ./.venv
key: venv-${{ hashFiles('poetry.lock') }}
- name: Install Python libraries 💾
run: poetry install
- name: Build site 👷
run: poetry run pelican -s publishconf.py
- name: Deploy 🚀
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: build # The folder the action should deploy.