Static Site Generators
Collection of Static Site Generators
Hugo
CLI
Github Workflow
name: Deploy Static Page
on:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
defaults:
run:
shell: bash
jobs:
build:
runs-on: ubuntu-latest
env:
HUGO_VERSION: 0.127.0
steps:
- name: Install Hugo CLI
run: |
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb
- name: Install Dart Sass
run: sudo snap install dart-sass
- name: Checkout
uses: actions/checkout@v4
- name: Build with Hugo
env:
HUGO_ENVIRONMENT: production
HUGO_ENV: production
run: hugo --minify
- name: Deploy
run: |
tar cf public.tar public/
curl -X POST -H "Authorization: Bearer ${{ secrets.TOKEN }}" -F [email protected] https://static.rehborn.org
Mkdocs
CLI
Github Workflow
name: Deploy Static Page
on:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
defaults:
run:
shell: bash
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: actions/setup-python@v5
- name: Install Dependencies
run: pip install mkdocs-material
- name: Build
run: |
mkdocs build
tar cf public.tar -C site/ .
- name: Deploy
run: |
curl -X POST -H "Authorization: Bearer ${{ secrets.TOKEN }}" -F [email protected] https://static.rehborn.org