docs-mastodon/.github/workflows/deploy.yml
Matt Jankowski ccaaa4d89d
Update hugo to version 0.140.2, GH actions to latest (#1573)
* Move pagination config to own section (deprecation warning)

* Update hugo to version 0.140.0

* Update actions/checkout to v4

* Update actions/configure-pages to v5

* Update actions/upload-pages-artifact to v3

* Update actions/deploy-pages to v4

* Update hugo to version 0.140.2
2025-01-10 17:02:17 +01:00

64 lines
1.4 KiB
YAML

name: Deploy on Github Pages
on:
push:
branches:
- main
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
# Default to bash
defaults:
run:
shell: bash
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: true # Fetch Hugo themes (true OR recursive)
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
- name: Setup Pages
id: pages
uses: actions/configure-pages@v5
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: "0.140.2"
extended: true
- name: Build
run: hugo --minify --baseURL "${{ steps.pages.outputs.base_url }}/"
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./public
# Deployment job
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4