Skip to content

Add a new mirror

Add a new mirror #21

Workflow file for this run

on:
workflow_dispatch:
pull_request:
paths:
- mirrors.yaml
- generate-site.py
- web/**
push:
branches:
- master
paths:
- mirrors.yaml
- generate-site.py
- web/**
name: Deploy to Github Pages
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: classabbyamp/treeless-checkout-action@v1
- name: Prepare
run: python3 -m venv env && env/bin/pip install PyYAML
- name: Create file structure
run: PYTHON=env/bin/python make deploy
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
deploy:
name: Deploy
runs-on: ubuntu-latest
needs: build
if: github.event_name != 'pull_request'
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1