Skip to content

docs(license): relicense under CC BY-NC-ND 4.0 #6

docs(license): relicense under CC BY-NC-ND 4.0

docs(license): relicense under CC BY-NC-ND 4.0 #6

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
name: Build Site
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Setup Hugo
uses: peaceiris/actions-hugo@v3
with:
hugo-version: "0.161.1"
extended: true
- name: Setup Go
# Required by Hugo Modules to fetch the Hugo Blox theme on first build.
uses: actions/setup-go@v6
with:
go-version: "1.22"
- name: Setup Node.js
# Hugo Blox needs preact + tailwindcss + pagefind at build time.
uses: actions/setup-node@v6
with:
node-version: "22"
- name: Install npm deps
run: npm install
- name: Build site
# node_modules/.bin must be on PATH so the tailwindcss CLI resolves.
run: |
export PATH="$PWD/node_modules/.bin:$PATH"
hugo --minify
- name: Build search index
run: npx pagefind --site public
# TODO(htmltrust): re-wire signed-section verification once the signing
# pipeline is integrated with the Hugo Blox build. The previous site
# signed its own pages at the layout level; the new site does not yet.
- uses: actions/upload-artifact@v7
with:
name: website
path: public/
deploy:
name: Deploy to Cloudflare Pages
runs-on: ubuntu-latest
needs: build
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
continue-on-error: true
steps:
- uses: actions/download-artifact@v8
with:
name: website
path: public/
- name: Deploy to Cloudflare Pages
uses: cloudflare/wrangler-action@v4
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
command: pages deploy public --project-name=htmltrust-website