https://github.com/kristoff-it/setup-zine
GitHub Action to get the Zine static site generator
https://github.com/kristoff-it/setup-zine
blog ssg zig
Last synced: about 1 year ago
JSON representation
GitHub Action to get the Zine static site generator
- Host: GitHub
- URL: https://github.com/kristoff-it/setup-zine
- Owner: kristoff-it
- License: mit
- Created: 2025-04-01T17:12:05.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-08T18:36:18.000Z (about 1 year ago)
- Last Synced: 2025-04-09T15:16:51.864Z (about 1 year ago)
- Topics: blog, ssg, zig
- Homepage: https://zine-ssg.io
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# setup-zine
GitHub Action to get the [Zine static site generator](https://zine-ssg.io).
# Usage
In your GitHub Actions workflow file add a step like this:
```yaml
- name: Setup Zine
uses: kristoff-it/setup-zine@v1
with:
version: v0.10.0
```
The `version` field is mandatory and must be `v0.10.0` or higher (previous
versions of Zine have no artifacts associated).
The action will make `zine` available in PATH, after that it's up to you to run `zine release`.
If you are using Zine in conjunction with Zig (i.e. you integrate Zine in your
`build.zig`) then using this action will allow you to avoid building Zine from
source by setting `.zine = .system` in `build.zig`.
That said, be aware that `mlugg/setup-zig` will save your Zig cache dir and so
building Zine will also be cached. The upside of using this action anyway is
that it will save you from "slow startups" when your cache expires.
# Full GitHub Pages workflow example.
```yaml
name: Deploy the website to Github Pages
on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Change if you need git info
- name: Setup Zine
uses: kristoff-it/setup-zine@v1
with:
version: v0.10.0-preview
- name: Release
run: zine release
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: 'public'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
```
This last example workflow will only work if you have setup GitHub Pages to deploy from GitHub Actions in your repo's settings section.