Skip to content

hakula139/kiln

Repository files navigation

kiln

CI codecov License: MIT Ask DeepWiki

A custom static site generator (SSG) written in Rust, replacing a Hugo + LoveIt stack for hakula.xyz.

Overview

kiln is purpose-built for hakula.xyz: strong CJK-friendly authoring, explicit rendering behavior, and a theme system that stays understandable. Instead of chasing broad SSG feature parity, it focuses on a smaller publishing workflow that is easier to reason about and extend.

Highlights

Authoring

  • TOML frontmatter, GitHub Flavored Markdown, KaTeX math
  • CJK-friendly heading IDs and table of contents generation
  • ::: directives with theme-template rendering
  • Directive template helpers (read_file, parse_csv)
  • Image attributes, emoji / icon shortcodes, and code-block presentation helpers

Site Generation

  • Pretty URLs, static file copying, co-located content assets
  • Home pages, section pages, standalone pages, taxonomy indexes, and paginated term pages
  • Configurable site time zones for rendered dates
  • RSS feeds, sitemap, custom 404 page
  • Full-text search via Pagefind

Theming

  • MiniJinja templates with layered site overrides and theme parameter merging
  • Ships with IgnIt: Tailwind CSS v4, glassmorphism panels with cursor-tracking glow, dark mode, responsive layout, search modal, back-to-top, mobile menu animations, print styles, keyboard accessibility

Tooling

  • Dev server with live reload (kiln serve)
  • Hugo-to-kiln content migration (kiln convert)

Documentation

Document Description
Roadmap Current shipped capability areas and planned work
Content Guide Page bundles, co-located assets, per-page CSS
Syntax Guide Markdown extensions, frontmatter fields, directives
Theming Theme installation, configuration, and creation

Current Focus

i18n groundwork, authoring enhancements (code-block attributes, bundled scripts), and further ergonomics polish. See the roadmap for details.

Usage

kiln build                                                  # Build the site
kiln build --root /path/to/site                             # Build from a specific root
kiln build --minify                                         # Build, then minify HTML / CSS / JS
kiln serve                                                  # Dev server with live reload
kiln serve --port 3000 --open                               # Custom port, auto-open browser
kiln init-theme my-theme                                    # Scaffold a new theme
kiln convert --source /path/to/hugo --dest /path/to/kiln    # Convert a Hugo site

Minification

Passing --minify to kiln build runs a Rust-native pass over the output directory and rewrites each HTML / CSS / JS file in place:

Files matching *.min.css or *.min.js are skipped so that pre-minified vendor bundles (e.g., Pagefind's UI JS) pass through untouched. Unusable inputs log a warning and keep the original file, so --minify never blocks a build.

Search

kiln integrates with Pagefind for full-text search. Install the binary (cargo install pagefind or npm install -g pagefind), then enable it in config.toml:

[search]
enabled = true
# binary = "/path/to/pagefind"    # optional, if not on $PATH

kiln build and kiln serve both run Pagefind automatically after HTML generation.

Building from Source

Requires Rust 1.85+ (edition 2024).

cargo build --release    # Binary at target/release/kiln

License

Copyright (c) 2026 Hakula. Licensed under the MIT License.

About

[WIP] A custom static site generator (SSG) written in Rust

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages