Skip to content

Deploy to GitHub Pages #60

Deploy to GitHub Pages

Deploy to GitHub Pages #60

Workflow file for this run

name: Deploy to GitHub Pages
on:
schedule:
- cron: '0 0 * * *'
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 20
- name: Cache Node.js modules
uses: actions/cache@v3
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install, build, and upload your site
uses: withastro/[email protected]
- name: Audit URLs using Lighthouse
uses: treosh/lighthouse-ci-action@v12
with:
uploadArtifacts: true
temporaryPublicStorage: true
deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/[email protected]