Skip to content

Merge pull request #4 from Codewriter90x/dependabot/github_actions/ac… #4

Merge pull request #4 from Codewriter90x/dependabot/github_actions/ac…

Merge pull request #4 from Codewriter90x/dependabot/github_actions/ac… #4

Workflow file for this run

name: GitHub Pages
on:
push:
branches:
- main
paths:
- ".github/workflows/pages.yml"
- "assets/social-preview.jpg"
- "data/italian_locations.csv"
- "scripts/build_pages.py"
- "site/**"
- "tests/pages_core.test.mjs"
- "tests/test_pages.py"
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: github-pages
cancel-in-progress: true
jobs:
build:
name: Build and test site
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Check out repository
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python
uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6
with:
python-version: "3.12"
- name: Test search and map logic
run: node --test tests/pages_core.test.mjs
- name: Test deterministic Pages build
run: python -m unittest discover -s tests -p "test_pages.py" -v
- name: Build GitHub Pages artifact
run: python scripts/build_pages.py --output _site
- name: Configure GitHub Pages
uses: actions/configure-pages@983d7736d9b0ae728b81ab479565c72886d7745b # v5
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4
with:
path: _site
deploy:
name: Deploy site
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
timeout-minutes: 10
steps:
- name: Deploy GitHub Pages
id: deployment
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4