Skip to content

Update the website

Update the website #11

Workflow file for this run

name: Update the website
on:
release:
types: [published]
workflow_dispatch:
inputs:
version:
description: "commit-ish to publish"
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Use latest Node.js
uses: actions/setup-node@v3
- name: Get version
run: |
if [ -n "${{ inputs.version }}" ]; then
echo COMMIT="${{ inputs.version }}" >> $GITHUB_ENV
else
echo COMMIT="${{ github.ref }}" >> $GITHUB_ENV
fi
- uses: actions/checkout@v3
with:
ref: ${{ env.COMMIT }}
sparse-checkout: |
README.md
sparse-checkout-cone-mode: false
- name: Upload to Github Pages
uses: actions/upload-pages-artifact@v2
with:
path: .
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2