Skip to content

ci(publish): initial setup of hugo build #201

ci(publish): initial setup of hugo build

ci(publish): initial setup of hugo build #201

Workflow file for this run

name: Publish
on:
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # for .GitInfo and .Lastmod
- uses: actions/setup-node@v4
with:
node-version-file: package.json
cache: npm
- run: npm ci
- run: npm run lint
- uses: peaceiris/actions-hugo@v3
with:
hugo-version: '0.141.0'
extended: true
- run: hugo build --minify
- uses: anishathalye/proof-html@v2
with:
directory: ./public
swap_urls: |
{"^https:\\/\\/mlo\\.io\\/": "/"}
# - uses: actions/upload-artifact@v4
# with:
# name: site
# path: dist/
# deploy:
# runs-on: ubuntu-latest
# needs: build
# permissions:
# contents: read
# deployments: write
# steps:
# - uses: actions/checkout@v4
# - uses: actions/download-artifact@v4
# with:
# name: site
# path: dist
# - uses: cloudflare/pages-action@v1
# with:
# apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
# accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
# projectName: mloberg
# directory: dist
# gitHubToken: ${{ secrets.GITHUB_TOKEN }}